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

Numbering a List - 1746 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 21
  • Number of attempts: 1
Reformat/Refactor a Golfer Class - 5551 entries

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

  • Best score: 32
  • Best player score: 38
  • Number of attempts: 2
Copy three lines - 2209 entries

If the site is up (by some miracle), make the text under every header identical.

  • Best score: 13
  • Best player score: 18
  • Number of attempts: 3
One number per line - 13841 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 18
  • Number of attempts: 1
Simple, Practical, and Common - 26338 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: 14
  • Best player score: 25
  • Number of attempts: 3
Collect List - 3579 entries

Convert to comma separated list.

  • Best score: 12
  • Best player score: 17
  • Number of attempts: 1
quotes inside quotes - 2826 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: 17
  • Number of attempts: 1
switch variable - 4390 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 11
  • Number of attempts: 3
V to the i - 4054 entries

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

  • Best score: 7
  • Best player score: 9
  • Number of attempts: 1
Split line with dots - 1894 entries

This line is too long, split it.

  • Best score: 15
  • Best player score: 15
  • Number of attempts: 6
I forgot quotes - 12471 entries

Oops.

  • Best score: 10
  • Best player score: 17
  • Number of attempts: 1
A Simple One - 849 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: 1
Generate English Alphabets - 413 entries

Start with a, get up to z.

  • Best score: 19
  • Best player score: 26
  • Number of attempts: 3
Vice versa - 6174 entries

Little role switching.

  • Best score: 12
  • Best player score: 16
  • Number of attempts: 2
Words in parens - 11277 entries

We should all ace this, right?

  • Best score: 14
  • Best player score: 16
  • Number of attempts: 1
Just the middle - 9554 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 7
  • Number of attempts: 3
Extract argument from function - 2037 entries

The aim is to see if you can do some refactoring very fast.

  • Best score: 13
  • Best player score: 15
  • Number of attempts: 1
Search and Replace 0 - 4187 entries

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

  • Best score: 12
  • Best player score: 14
  • Number of attempts: 4
-a-b-c- - 2670 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 16
  • Number of attempts: 1
Jonathan Elliott
Twitter:

I like maths, crosswords and beer.

entered into 19 challenges

contributed 0 challenges