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

Counting in binary - 393 entries

"a" represents 0; "A" represents 1. Start from zero and count to 15.

  • Best score: 16
  • Best player score: 69
  • Number of attempts: 1
Reformat/Refactor a Golfer Class - 5570 entries

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

  • Best score: 32
  • Best player score: 51
  • Number of attempts: 3
Create Leading Zeros - 192 entries

Create leading zeros only for id columns. Please use generic approach!

  • Best score: 23
  • Best player score: 31
  • Number of attempts: 1
Letter case trickery - 1451 entries

This file is in a downright esoteric format, consisting of hexadecimal numbers, non-hexadecimal keywords, and "Z" indicating end-of-line. Make the hexadecimal numbers lowercase.

  • Best score: 9
  • Best player score: 23
  • Number of attempts: 3
quotes inside quotes - 2844 entries

taken from tip 85 of the very good book 'Practical Vim: Edit Text at the Speed of Thought' ! I'd be interested what people use :)

  • Best score: 14
  • Best player score: 15
  • Number of attempts: 3
switch variable - 4448 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 16
  • Number of attempts: 4
Saving the hashes(#) - 1806 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: 28
  • Number of attempts: 5
Hole-in-one - 947 entries

Lets take this golf thing literally.. Drive off the tee into the hole, and of course you don't strike the ball completely clean.

  • Best score: 15
  • Best player score: 20
  • Number of attempts: 2
Words in parens - 11439 entries

We should all ace this, right?

  • Best score: 14
  • Best player score: 21
  • Number of attempts: 4
Simple text editing with Vim - 10703 entries

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

  • Best score: 13
  • Best player score: 17
  • Number of attempts: 3
Ian Oxley
Twitter:

I build things on the Web, play guitar, and take the odd photo.

entered into 10 challenges

contributed 0 challenges