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

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

155 active golfers, 879 entries

Solutions by @somemeatjain:
31
#31 - Sammit / @somemeatjain

02/05/2022 at 12:32PM

33
#>37 - Sammit / @somemeatjain

02/05/2022 at 12:28PM

34
#>46 - Sammit / @somemeatjain

02/05/2022 at 12:26PM

35
#>47 - Sammit / @somemeatjain

02/05/2022 at 12:24PM

36
#>49 - Sammit / @somemeatjain

02/05/2022 at 12:23PM

37
#>50 - Sammit / @somemeatjain

02/05/2022 at 12:17PM

38
#>53 - Sammit / @somemeatjain

02/05/2022 at 12:15PM

39
#>59 - Sammit / @somemeatjain

02/05/2022 at 12:11PM

40
#>61 - Sammit / @somemeatjain

02/05/2022 at 12:09PM

41
#>64 - Sammit / @somemeatjain

02/05/2022 at 12:08PM

42
#>64 - Sammit / @somemeatjain

02/05/2022 at 12:06PM

44
#>70 - Sammit / @somemeatjain

02/05/2022 at 12:05PM

45
#>77 - Sammit / @somemeatjain

02/05/2022 at 11:58AM

47
#>92 - Sammit / @somemeatjain

02/05/2022 at 11:42AM

57
#>119 - Sammit / @somemeatjain

02/05/2022 at 11:33AM