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

Simple, Practical, and Common - 33385 entries

Simple things we do all the time should be able to be done with very few keystrokes, but sometimes I find something I need to do makes me go, "There MUST be a better way." This challenge is just a simple movement and entering text at a certain place.

  • Best score: 22
  • Best player score: 27
  • Position: #3882 / 7364
  • Number of attempts: 4
V to the i - 4751 entries

Input is 99 V's. Output is 100 i's.

  • Best score: 7
  • Best player score: 7
  • Position: #54 / 1879
  • Number of attempts: 3
Add semicolons - 10792 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 12
  • Position: #1824 / 3044
  • Number of attempts: 1
Just the middle - 11360 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 9
  • Position: #3315 / 4164
  • Number of attempts: 2
Extended Customer 2 - 47 entries

Format the chars

  • Best score: 47
  • Best player score: 73
  • Position: #13 / 20
  • Number of attempts: 2
I forgot quotes - 15931 entries

Oops.

  • Best score: 10
  • Best player score: 16
  • Position: #2423 / 4161
  • Number of attempts: 3
Do you demand a shrubbery? - 1120 entries

Use :redir and crush the emacsgolfers.

  • Best score: 15
  • Best player score: 23
  • Position: #184 / 293
  • Number of attempts: 1
Don't know what this is - 1978 entries

Replace contents of brackets with matching number of spaces. Don't ask what the format's supposed to be.

  • Best score: 11
  • Best player score: 16
  • Position: #474 / 578
  • Number of attempts: 2
paste indent correction - JS - 102 entries

You copy some javascript code from a website and paste it into vim, it does not look good!

  • Best score: 16
  • Best player score: 16
  • Position: #6 / 57
  • Number of attempts: 2
Delete unwanted lines - 396 entries

Delete all lines which does not end in "o.."

  • Best score: 9
  • Best player score: 9
  • Position: #31 / 225
  • Number of attempts: 1
Lookahead and Lookbehind - 67 entries

Look everywhere

  • Best score: 16
  • Best player score: 26
  • Position: #26 / 29
  • Number of attempts: 1
Minimalist Limerick - 516 entries

Reproduce this lovely poem.

  • Best score: 31
  • Best player score: 37
  • Position: #100 / 171
  • Number of attempts: 3
Enumerate words - 250 entries

Enumerate the unique words in order.

  • Best score: 23
  • Best player score: 27
  • Position: #58 / 89
  • Number of attempts: 1
Block Fun 1 - 189 entries

Manipulate the columns to produce desired result.

  • Best score: 14
  • Best player score: 24
  • Position: #54 / 73
  • Number of attempts: 2
The Quick Brown Fox Jumps Over The Lazy Vim - 401 entries

Someone has vandalized this text file and replaced the beginning character of one word in each line with a Big "X." Please remove the big X's, and fix each line to read "The Quick Brown Fox Jumps Over The Lazy Dog."

  • Best score: 8
  • Best player score: 10
  • Position: #52 / 188
  • Number of attempts: 2
lamb had a little Mary - 586 entries

"Mary" and "lamb" are swapped. Unswap them. Fast as you can.

  • Best score: 16
  • Best player score: 39
  • Position: #125 / 163
  • Number of attempts: 1
Saving the hashes(#) - 1992 entries

The following file is copied from vimcasts.org(Its only for learning purpose,hope the site owner doesn't mind it), its probably the easiest of challenges.Our goal is to delete every line which doesn't contain a hash signs. The remaining hash signs with numbers are then sorted to get the final output.

  • Best score: 20
  • Best player score: 29
  • Position: #306 / 473
  • Number of attempts: 1
Vertical Limit - 2448 entries

transform a succession of one word lines to a an array of strings

  • Best score: 21
  • Best player score: 24
  • Position: #267 / 738
  • Number of attempts: 7
Alphabetize the directory - 283 entries

Put the contacts and their information in alphabetical order.

  • Best score: 30
  • Best player score: 39
  • Position: #78 / 99
  • Number of attempts: 1
Numbering a List - 1859 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 25
  • Position: #515 / 639
  • Number of attempts: 1
Change the content of a string - 1476 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 25
  • Position: #346 / 558
  • Number of attempts: 1
Simple text editing with Vim - 12290 entries

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

  • Best score: 13
  • Best player score: 13
  • Position: #139 / 3581
  • Number of attempts: 4
Joshua Draper
Twitter:

entered into 22 challenges

contributed 0 challenges