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

Wrap the text of an email message to 79 characters - 800 entries

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

  • Best score: 5
  • Best player score: 5
  • Position: #49 / 422
  • Number of attempts: 2
Search and Replace 0 - 5007 entries

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

  • Best score: 12
  • Best player score: 12
  • Position: #110 / 1631
  • Number of attempts: 5
Turn this csv list into queries - 252 entries

Transform each line of this csv file into a MySQL-ready INSERT query.

  • Best score: 98
  • Best player score: 142
  • Position: #79 / 101
  • Number of attempts: 1
Reformat a C golf submission - 614 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: 22
  • Best player score: 43
  • Position: #187 / 210
  • Number of attempts: 1
Change the content of a string - 1600 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 26
  • Position: #402 / 596
  • Number of attempts: 2
Deleting folded text - 386 entries

The text below contains three folds. Delete them (and the text inside them). For example: 123 456 /*{{{*/ 789 /*}}}*/ 012 Should become: 123 012 Also, add `aoeuaoeu` to make sure small solutions don't get flagged as cheating.

  • Best score: 17
  • Best player score: 22
  • Position: #86 / 121
  • Number of attempts: 1
Sort and add attributes - 1480 entries

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

  • Best score: 33
  • Best player score: 36
  • Position: #433 / 576
  • Number of attempts: 2
Add fold markers to a .c file - 662 entries

Fold markers can make it easier to navigate source code. Add them to this .c file.

  • Best score: 30
  • Best player score: 30
  • Position: #6 / 190
  • Number of attempts: 5
Reconstruct the Sentence - 1599 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: 24
  • Position: #306 / 426
  • Number of attempts: 3
Braces or Brackets? - 1056 entries

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

  • Best score: 34
  • Best player score: 52
  • Position: #256 / 325
  • Number of attempts: 1
Whitespace, empty lines and tabs - 3763 entries

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

  • Best score: 16
  • Best player score: 32
  • Position: #587 / 807
  • Number of attempts: 1
Simple text editing with Vim - 13013 entries

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

  • Best score: 13
  • Best player score: 24
  • Position: #3107 / 3744
  • Number of attempts: 3
Reformat/Refactor a Golfer Class - 7173 entries

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

  • Best score: 28
  • Best player score: 42
  • Position: #954 / 1761
  • Number of attempts: 7
Craig H. Anderson
Twitter:

entered into 13 challenges

contributed 0 challenges