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

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

129 active golfers, 674 entries

Solutions by @KnightdeadJohn:
31
#15 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 09:15AM

33
#>24 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 09:12AM

34
#>30 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 09:07AM

38
#>39 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:57AM

39
#>44 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:52AM

40
#>46 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:51AM

42
#>48 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:48AM

44
#>52 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:46AM

58
#>95 - Jonathan Stinson / @KnightdeadJohn

02/19/2020 at 08:25AM

65
#>104 - Jonathan Stinson / @KnightdeadJohn

02/18/2020 at 05:28PM