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 [challenge ID]

Played Challenges

One number per line - 18616 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 20
  • Position: #2231 / 3842
  • Number of attempts: 3
Applying same text modification in several lines - 2845 entries

Remove identical text at the beginning of several lines and the closing parenthesis.

  • Best score: 12
  • Best player score: 18
  • Position: #671 / 840
  • Number of attempts: 2
Add semicolons - 10792 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 11
  • Position: #1033 / 3044
  • Number of attempts: 2
remove lines containing the word "reader" - 3537 entries

easy stuff

  • Best score: 9
  • Best player score: 9
  • Position: #252 / 1144
  • Number of attempts: 4
Every other line - 2886 entries

AaAaAaA

  • Best score: 12
  • Best player score: 21
  • Position: #635 / 700
  • Number of attempts: 1
Search and Replace 0 - 4790 entries

Replace every instance of 'aaa' with 'xaaax'.

  • Best score: 12
  • Best player score: 16
  • Position: #1203 / 1585
  • Number of attempts: 1
comment and uncomment code inline - 1069 entries

It's very useful to be able to comment out a block of code in a quick edit. And likewise to uncomment the code. This operation often involves multi-line stanzas and even large blocks. With just line-wise navigation and insert mode this would cost you about 4 keystrokes per line. Master this hole of VimGolf and you'll quickly drop your key count in day to day Vim as well.

  • Best score: 9
  • Best player score: 19
  • Position: #299 / 314
  • Number of attempts: 1
Just the middle - 11360 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #2891 / 4164
  • Number of attempts: 2
change parenthesis - 278 entries

change the pair of braces into a pair of parentheses

  • Best score: 9
  • Best player score: 10
  • Position: #117 / 156
  • Number of attempts: 2
Collect List - 4264 entries

Convert to comma separated list.

  • Best score: 12
  • Best player score: 24
  • Position: #1149 / 1186
  • Number of attempts: 1
I forgot quotes - 15931 entries

Oops.

  • Best score: 10
  • Best player score: 18
  • Position: #3330 / 4161
  • Number of attempts: 5
Adrien
Twitter:

Administrateur système Linux, Cofondateur et développeur de la solution d'auto hébergement Yunohost #Linux #Debian #Yunohost

entered into 11 challenges

contributed 0 challenges