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

remove dupes from array - 1358 entries

given a random string that contains a ruby-esque array, make sure that there are no duplicate elements

  • Best score: 17
  • Best player score: 24
  • Position: #215 / 336
  • Number of attempts: 3
Numbering a List - 1932 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 19
  • Position: #183 / 653
  • Number of attempts: 7
Getters & Setters: Java - 211 entries

Boilerplate getters & setters - it's a tedious fact of life in Java, and probably the only thing that still pulls me back to an IDE. Perhaps someone knows a fast, pure vim way...

  • Best score: 89
  • Best player score: 160
  • Position: #54 / 59
  • Number of attempts: 1
Ruby 1.9 hashes - 1244 entries

Rubyists talk about being cutting edge but how many are using 1.9 in production? Time to convert those verbose 1.8 hashes in to symbolic, succinct 1.9 beauties!

  • Best score: 12
  • Best player score: 18
  • Position: #338 / 406
  • Number of attempts: 3
Assignment Alignment - 883 entries

line up the operators. Use spaces, not tabs.

  • Best score: 18
  • Best player score: 25
  • Position: #118 / 220
  • Number of attempts: 5
A Simple One - 1051 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
  • Position: #239 / 665
  • Number of attempts: 4
Ruby 1.9 compat - 629 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: 21
  • Position: #209 / 234
  • Number of attempts: 3
Change the content of a string - 1588 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 29
  • Position: #519 / 592
  • Number of attempts: 1
Braces or Brackets? - 1033 entries

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

  • Best score: 34
  • Best player score: 53
  • Position: #261 / 320
  • Number of attempts: 1
Simple text editing with Vim - 12856 entries

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

  • Best score: 13
  • Best player score: 27
  • Position: #3254 / 3707
  • Number of attempts: 4
Reformat/Refactor a Golfer Class - 7023 entries

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

  • Best score: 28
  • Best player score: 48
  • Position: #1304 / 1720
  • Number of attempts: 1
Daniel Harrington
Twitter:

entered into 11 challenges

contributed 0 challenges