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

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

146 active golfers, 819 entries

Solutions by @dorianm:
37
#46 - dorianm / @dorianm

05/08/2022 at 03:46AM

38
#>48 - dorianm / @dorianm

05/08/2022 at 03:45AM

39
#>54 - dorianm / @dorianm

05/08/2022 at 03:42AM

40
#>56 - dorianm / @dorianm

05/08/2022 at 03:41AM

41
#>59 - dorianm / @dorianm

05/08/2022 at 03:39AM

43
#>62 - dorianm / @dorianm

05/08/2022 at 03:35AM

44
#>65 - dorianm / @dorianm

05/08/2022 at 03:05AM

45
#>72 - dorianm / @dorianm

05/08/2022 at 02:58AM

47
#>87 - dorianm / @dorianm

05/08/2022 at 02:55AM

48
#>91 - dorianm / @dorianm

05/08/2022 at 02:36AM

48
#>91 - dorianm / @dorianm

05/08/2022 at 02:54AM

49
#>93 - dorianm / @dorianm

05/08/2022 at 02:33AM

52
#>98 - dorianm / @dorianm

05/08/2022 at 02:27AM