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

Swap function parameters and delete all comments in python. - 1036 entries

Swap function parameters and delete all comments in python.

  • Best score: 19
  • Best player score: 20
  • Position: #69 / 251
  • Number of attempts: 8
Delete the last function argument in python. - 707 entries

Delete the last function argument in this python script.

  • Best score: 6
  • Best player score: 6
  • Position: #64 / 253
  • Number of attempts: 3
Sort and Tag - 737 entries

The goal is to sort these lines alphabetically, assign a unique identifier to each line in the format "[01]", "[02]", etc., and then restore the original order of the lines while preserving the assigned identifiers.

  • Best score: 36
  • Best player score: 116
  • Position: #108 / 156
  • Number of attempts: 2
Copy punctuation - 755 entries

I want to copy the last line’s brackets, quotes, and commas to each line. How?

  • Best score: 19
  • Best player score: 37
  • Position: #96 / 186
  • Number of attempts: 4
Search and Replace 0 - 5167 entries

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

  • Best score: 12
  • Best player score: 12
  • Position: #765 / 1677
  • Number of attempts: 3
Get rid of html tags - 465 entries

Want to read more about Vim's background? Then get rid of those html tags...

  • Best score: 12
  • Best player score: 17
  • Position: #157 / 262
  • Number of attempts: 2
Reconstruct the Sentence - 1757 entries

Get the sentence back in the proper order, remove duplicate lines, and then combine the separate lines into one.

  • Best score: 19
  • Best player score: 19
  • Position: #12 / 459
  • Number of attempts: 7
Braces or Brackets? - 1209 entries

Someone forgot whether to use braces or brackets and you have to clean up their code!

  • Best score: 34
  • Best player score: 47
  • Position: #213 / 365
  • Number of attempts: 4
Whitespace, empty lines and tabs - 4070 entries

Convert tabs to spaces, strip empty lines and trailing whitespace.

  • Best score: 16
  • Best player score: 22
  • Position: #371 / 868
  • Number of attempts: 9
Simple text editing with Vim - 13667 entries

Make the pairs of lines match up by making each second line same as first

  • Best score: 13
  • Best player score: 31
  • Position: #3610 / 3914
  • Number of attempts: 3
Reformat/Refactor a Golfer Class - 7722 entries

A simple case of removing unneeded code and fixing broken indentation.

  • Best score: 7
  • Best player score: 40
  • Position: #914 / 1896
  • Number of attempts: 5
Jorrit Stramer
Github:

entered into 11 challenges

contributed 0 challenges