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

129 active golfers, 674 entries

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

02/16/2020 at 10:44PM

33
#>23 - howanto / @ho_wan_

02/16/2020 at 10:46PM

33
#>23 - howanto / @ho_wan_

02/16/2020 at 10:54PM

34
#>30 - howanto / @ho_wan_

02/16/2020 at 10:40PM

38
#>39 - howanto / @ho_wan_

02/16/2020 at 10:15PM

38
#>39 - howanto / @ho_wan_

02/16/2020 at 10:34PM

39
#>44 - howanto / @ho_wan_

02/16/2020 at 10:09PM

41
#>47 - howanto / @ho_wan_

02/16/2020 at 10:06PM

42
#>48 - howanto / @ho_wan_

02/16/2020 at 10:04PM

44
#>52 - howanto / @ho_wan_

02/16/2020 at 10:01PM

47
#>71 - howanto / @ho_wan_

02/16/2020 at 09:52PM

56
#>89 - howanto / @ho_wan_

02/16/2020 at 09:48PM

59
#>98 - howanto / @ho_wan_

02/16/2020 at 09:33PM

60
#>100 - howanto / @ho_wan_

02/16/2020 at 09:30PM

98
#>119 - howanto / @ho_wan_

02/16/2020 at 09:26PM