Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put 5e319945224f4100097c9609

Aliases for cd

Create these beautiful aliases with as few strokes as possible. Are you up for the challenge?

Start file
alias c.='cd ..'
End file
alias c.='cd ..'
alias c..='cd ../..'
alias c...='cd ../../..'
alias c....='cd ../../../..'
alias c.....='cd ../../../../..'

alias c1='cd ..'
alias c2='cd ../..'
alias c3='cd ../../..'
alias c4='cd ../../../..'
alias c5='cd ../../../../..'

View Diff

1a2,11
> alias c..='cd ../..'
> alias c...='cd ../../..'
> alias c....='cd ../../../..'
> alias c.....='cd ../../../../..'
> 
> alias c1='cd ..'
> alias c2='cd ../..'
> alias c3='cd ../../..'
> alias c4='cd ../../../..'
> alias c5='cd ../../../../..'

Solutions by @ho_wan_:

Unlock 15 remaining solutions by signing in and submitting your own entry
Created by: @rax0m

150 active golfers, 849 entries

Solutions by @ho_wan_:
33
#33 - howanto / @ho_wan_

02/16/2020 at 10:44PM

33
#>33 - howanto / @ho_wan_

02/16/2020 at 10:46PM

33
#>33 - howanto / @ho_wan_

02/16/2020 at 10:54PM

34
#>40 - howanto / @ho_wan_

02/16/2020 at 10:40PM

38
#>51 - howanto / @ho_wan_

02/16/2020 at 10:15PM

38
#>51 - howanto / @ho_wan_

02/16/2020 at 10:34PM

39
#>56 - howanto / @ho_wan_

02/16/2020 at 10:09PM

41
#>60 - howanto / @ho_wan_

02/16/2020 at 10:06PM

42
#>62 - howanto / @ho_wan_

02/16/2020 at 10:04PM

44
#>67 - howanto / @ho_wan_

02/16/2020 at 10:01PM

47
#>88 - howanto / @ho_wan_

02/16/2020 at 09:52PM

56
#>109 - howanto / @ho_wan_

02/16/2020 at 09:48PM

59
#>119 - howanto / @ho_wan_

02/16/2020 at 09:33PM

60
#>121 - howanto / @ho_wan_

02/16/2020 at 09:30PM

98
#>140 - howanto / @ho_wan_

02/16/2020 at 09:26PM