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 @roudens2:

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

146 active golfers, 819 entries

Solutions by @roudens2:
31
#25 - roudens / @roudens2

12/19/2020 at 05:32PM

32
#>27 - roudens / @roudens2

12/19/2020 at 04:43PM

33
#>32 - roudens / @roudens2

12/19/2020 at 03:59PM

34
#>41 - roudens / @roudens2

12/19/2020 at 03:53PM

35
#>42 - roudens / @roudens2

12/19/2020 at 05:25PM

36
#>44 - roudens / @roudens2

12/19/2020 at 03:49PM

37
#>44 - roudens / @roudens2

12/19/2020 at 03:41PM

43
#>62 - roudens / @roudens2

12/19/2020 at 03:19PM

45
#>71 - roudens / @roudens2

12/19/2020 at 03:13PM

46
#>83 - roudens / @roudens2

12/19/2020 at 11:01AM