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

Remember FizzBuzz? - 513 entries

Output FizzBuzz to 100. Start with nothing.

  • Best score: 39
  • Best player score: 63
  • Number of attempts: 2
Sorting paragraphs - 437 entries

Order the paragraphs correctly, per prefixed index

  • Best score: 18
  • Best player score: 33
  • Number of attempts: 1
Reverse Simple Deletion - 694 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Number of attempts: 1
Ruby 1.9 compat - 545 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: 14
  • Number of attempts: 4
Context insensitive completion 0 - 441 entries

Buried in the lines you're not supposed to add is the line "Add this line!" Add that line to the top of the file.

  • Best score: 7
  • Best player score: 7
  • Number of attempts: 2
Increment, increment, increment.... - 472 entries

Vim likes macros

  • Best score: 10
  • Best player score: 12
  • Number of attempts: 2
Get rid of html tags - 303 entries

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

  • Best score: 15
  • Best player score: 26
  • Number of attempts: 3
Reverse characters in a line - 554 entries

You have everything you need, just not in the right order. Mastermind would give you 26 white pegs.

  • Best score: 12
  • Best player score: 13
  • Number of attempts: 4
Change the content of a string - 1208 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 22
  • Number of attempts: 2
Simple text editing with Vim - 10007 entries

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

  • Best score: 13
  • Best player score: 13
  • Number of attempts: 5
The Cake is a Lie - 1106 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 9
  • Number of attempts: 2
Search and Replace 0 - 3875 entries

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

  • Best score: 12
  • Best player score: 12
  • Number of attempts: 4
Interweave two blocks of text - 475 entries

Suppose you've got data on a list of things from multiple sources. They're all in separate chunks, so how might you create a tabular output?

  • Best score: 15
  • Best player score: 17
  • Number of attempts: 1
Reformat a C golf submission - 464 entries

Take this C golf submission (for the "tiny but standards-compliant Hello World program" category, naturally), and turn it into formatted C code.

  • Best score: 23
  • Best player score: 41
  • Number of attempts: 1
Hatsuyume - 360 entries

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

  • Best score: 16
  • Best player score: 24
  • Number of attempts: 5
A Simple One - 827 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: 3
Wrap the text of an email message to 79 characters - 478 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
Reconstruct the Sentence - 1010 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: 20
  • Number of attempts: 3
Round Round - 240 entries

Round Round

  • Best score: 19
  • Best player score: 109
  • Number of attempts: 1
Line Zipper - 388 entries

Zip/pair related lines.

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

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

  • Best score: 16
  • Best player score: 19
  • Number of attempts: 6
Case preserving word replacement - 383 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: 19
  • Number of attempts: 4
Fix the Haiku - 246 entries

Change this slightly scrambled haiku to its unscrambled form and fix the capitalisation and punctuation along the way.

  • Best score: 28
  • Best player score: 47
  • Number of attempts: 1
Numbering a List - 1707 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 19
  • Number of attempts: 4
imports alignment (python) - 571 entries

Align as one import per line.

  • Best score: 17
  • Best player score: 20
  • Number of attempts: 4
Compile C - 275 entries

You might have to get clever to do this one.

  • Best score: 19
  • Best player score: 21
  • Number of attempts: 2
Sort and add attributes - 1059 entries

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

  • Best score: 18
  • Best player score: 33
  • Number of attempts: 3
Sammasati
Twitter:

entered into 27 challenges

contributed 0 challenges