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

Braces or Brackets? - 625 entries

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

  • Best score: 34
  • Best player score: 37
  • Number of attempts: 3
Reformat/Refactor a Golfer Class - 5464 entries

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

  • Best score: 32
  • Best player score: 36
  • Number of attempts: 1
Sort and add attributes - 1067 entries

Sort the states and add the attribute country to each record.

  • Best score: 18
  • Best player score: 33
  • Number of attempts: 1
Flodder-challenge - 804 entries

Replace the text the most efficient and win!

  • Best score: 27
  • Best player score: 28
  • Number of attempts: 2
Python Hello World! Reformatting - 825 entries

A novice Python using prints Hello World! and a pro shows him different way. Using vim to get into pro style from novice, win the challenge.

  • Best score: 39
  • Best player score: 44
  • Number of attempts: 1
Reverse and count - 379 entries

Someone typed things upside down and now a Vim ninja needs to reverse the lines and count how many there are.

  • Best score: 18
  • Best player score: 24
  • Number of attempts: 3
Assignment Alignment - 682 entries

line up the operators. Use spaces, not tabs.

  • Best score: 18
  • Best player score: 22
  • Number of attempts: 3
Sort the cardinal numbers - 211 entries

Maybe a simple challenge.

  • Best score: 12
  • Best player score: 12
  • Number of attempts: 2
Reconstruct the Sentence - 1016 entries

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

  • Best score: 20
  • Best player score: 21
  • Number of attempts: 1
A Simple One - 832 entries

Here is a very simple one - just to illustrate/introduce a vim feature that some people seem to miss...

  • Best score: 9
  • Best player score: 9
  • Number of attempts: 1
Almost encrypted - 164 entries

Convert the first paragraph to be even less readable.

  • Best score: 5
  • Best player score: 5
  • Number of attempts: 1
Wrap the text of an email message to 79 characters - 481 entries

You're replying to an email with silly long lines. Clean them up.

  • Best score: 5
  • Best player score: 5
  • Number of attempts: 1
Hatsuyume - 363 entries

http://en.wikipedia.org/wiki/Hatsuyume

  • Best score: 16
  • Best player score: 24
  • Number of attempts: 4
Simple text editing with Vim - 10275 entries

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

  • Best score: 13
  • Best player score: 14
  • Number of attempts: 7
Change the content of a string - 1222 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 22
  • Number of attempts: 3
Search and Replace 0 - 4019 entries

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

  • Best score: 12
  • Best player score: 12
  • Number of attempts: 2
Ruby 1.9 compat - 556 entries

Remember when Ruby supported `when <expr> :`? Well, it doesn't in 1.9, so let's make sure we use `then`, without ruining our lovely new hash syntax!

  • Best score: 14
  • Best player score: 16
  • Number of attempts: 2
The holy-grail may help - 298 entries

Can you find it in less than 20 strokes, Arthur?

  • Best score: 16
  • Best player score: 16
  • Number of attempts: 1
Whitespace, empty lines and tabs - 2529 entries

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

  • Best score: 16
  • Best player score: 19
  • Number of attempts: 7
Case preserving word replacement - 384 entries

Half way through my project, my people turned into dogs. Now I have to change everything in my source.

  • Best score: 19
  • Best player score: 20
  • Number of attempts: 6
Terje Larsen
Twitter:

entered into 20 challenges

contributed 0 challenges