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

Collect List - 3956 entries

Convert to comma separated list.

  • Best score: 12
  • Best player score: 16
  • Number of attempts: 1
Words in parens - 12151 entries

We should all ace this, right?

  • Best score: 14
  • Best player score: 16
  • Number of attempts: 2
Pairs of numbers - 340 entries

Line 1 represents x, line 2 y-data. Bring the corresponding pairs in the form "[x,y]\n"

  • Best score: 26
  • Best player score: 45
  • Number of attempts: 1
switch variable - 4696 entries

how fast can you switch two variable ?

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

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

  • Best score: 12
  • Best player score: 14
  • Number of attempts: 1
Extract argument from function - 2136 entries

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

  • Best score: 13
  • Best player score: 16
  • Number of attempts: 1
Sort and add attributes - 1113 entries

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

  • Best score: 33
  • Best player score: 38
  • Number of attempts: 2
Exchanging Quotes - 777 entries

Sometimes you need to exchange a choice of quotes in some code.

  • Best score: 30
  • Best player score: 42
  • Number of attempts: 1
The Quick Brown Fox Jumps Over The Lazy Vim - 339 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: 10
  • Best player score: 11
  • Number of attempts: 1
Where should I put the Newline? - 830 entries

Help me put the newline.

  • Best score: 7
  • Best player score: 8
  • Number of attempts: 2
Just the middle - 10565 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Number of attempts: 1
Reformat/Refactor a Golfer Class - 5698 entries

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

  • Best score: 32
  • Best player score: 44
  • Number of attempts: 1
Simple text editing with Vim - 11104 entries

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

  • Best score: 13
  • Best player score: 18
  • Number of attempts: 1
Saving the hashes(#) - 1876 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: 36
  • Number of attempts: 2
quotes inside quotes - 2952 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
Make it more readable - 1812 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 17
  • Number of attempts: 2
Shebangs for all - 1672 entries

We've all seen or used a shebang once or twice. Ditch the specific paths and leave just a dynamic Ruby and Python bath behind.

  • Best score: 11
  • Best player score: 23
  • Number of attempts: 1
-a-b-c- - 2925 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 17
  • Number of attempts: 1
Simple, Practical, and Common - 30753 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: 29
  • Number of attempts: 2
learn vim in short time - 196 entries

so happy to learn vim.because vim is awesome

  • Best score: 8
  • Best player score: 8
  • Number of attempts: 1
Brian Besmanoff
Twitter:

entered into 20 challenges

contributed 0 challenges