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 - 32765 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: 22
  • Position: #1610 / 7241
  • Number of attempts: 13
One number per line - 18294 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 14
  • Position: #483 / 3770
  • Number of attempts: 7
Swap values inside brackets - 2417 entries

Easy challenge.

  • Best score: 14
  • Best player score: 35
  • Position: #534 / 557
  • Number of attempts: 4
Applying same text modification in several lines - 2710 entries

Remove identical text at the beginning of several lines and the closing parenthesis.

  • Best score: 12
  • Best player score: 13
  • Position: #75 / 806
  • Number of attempts: 4
Swap the operands under comparison - 251 entries

Swap the operands under comparison to prevent null pointer exception (at least in java)

  • Best score: 19
  • Best player score: 24
  • Position: #57 / 90
  • Number of attempts: 1
remove lines containing the word "reader" - 3436 entries

easy stuff

  • Best score: 9
  • Best player score: 9
  • Position: #59 / 1113
  • Number of attempts: 7
Com(m)a Trouble - 3307 entries

Someone was real stupid when placing his commas. Can you fix it?

  • Best score: 12
  • Best player score: 12
  • Position: #14 / 746
  • Number of attempts: 10
Every other line - 2790 entries

AaAaAaA

  • Best score: 12
  • Best player score: 17
  • Position: #489 / 679
  • Number of attempts: 5
Preferably without multi-cursor plugin - 459 entries

Originally asked as question on reddit by kpthunder: https://www.reddit.com/r/vim/comments/9fvsro/what_is_the_most_efficient_way_to_go_about/

  • Best score: 30
  • Best player score: 33
  • Position: #43 / 114
  • Number of attempts: 7
Team names - 1763 entries

The team names are misspelled.

  • Best score: 16
  • Best player score: 16
  • Position: #204 / 566
  • Number of attempts: 7
For all cases. - 123 entries

In this case... change it! :) Watch the line.

  • Best score: 8
  • Best player score: 8
  • Position: #62 / 87
  • Number of attempts: 3
Stairstep digits - 238 entries

Remove the evens. Double the odds.

  • Best score: 9
  • Best player score: 13
  • Position: #95 / 113
  • Number of attempts: 3
Missing Library and a Typo - 826 entries

I forgot to add a c library, please add it for me. Also I'm bad at typing so fix my typo too.

  • Best score: 15
  • Best player score: 19
  • Position: #135 / 202
  • Number of attempts: 4
Adam's challenge - 905 entries

Change both normal to bold and 4 by 2. Adam Wathan challenge this on twitter . He did it in 11 keystrokes on Sublime.

  • Best score: 18
  • Best player score: 21
  • Position: #151 / 253
  • Number of attempts: 11
Order and join - 853 entries

There's something special about the input order.

  • Best score: 10
  • Best player score: 10
  • Position: #60 / 235
  • Number of attempts: 7
Python challenge - 128 entries

Change the types of the variables in the list from str to float, while keeping the truncation.

  • Best score: 31
  • Best player score: 59
  • Position: #31 / 39
  • Number of attempts: 3
One to Ten - 2071 entries

Generate the sequence of numbers from 1 to 10, one number per line. Inspired by this Reddit thread: https://redd.it/ak4it2

  • Best score: 12
  • Best player score: 12
  • Position: #18 / 634
  • Number of attempts: 3
Change part of a function name in multiple occurrences - 595 entries

Change the middle part of the function name in multiple places, preferably using the next and dot commands.

  • Best score: 14
  • Best player score: 14
  • Position: #15 / 190
  • Number of attempts: 5
Delete to the end of the current line - 711 entries

Delete to the end of the current line, but keep the character under the cursor.

  • Best score: 5
  • Best player score: 5
  • Position: #22 / 348
  • Number of attempts: 2
Put the months in order - 915 entries

Our contractor thought that months should be in alphabetical order. Put them in calendar order please.

  • Best score: 20
  • Best player score: 31
  • Position: #44 / 155
  • Number of attempts: 6
convert yml into java pojo field - 801 entries

How fast vim can create fields for java pojo i.e class declaration referring to a (simple) yml file

  • Best score: 29
  • Best player score: 29
  • Position: #54 / 213
  • Number of attempts: 6
Simple format (2) - 306 entries

try again!

  • Best score: 23
  • Best player score: 34
  • Position: #45 / 64
  • Number of attempts: 3
I forgot quotes - 15666 entries

Oops.

  • Best score: 10
  • Best player score: 14
  • Position: #1786 / 4098
  • Number of attempts: 6
Don't know what this is - 1923 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: 17
  • Position: #530 / 565
  • Number of attempts: 5
Santa's naughty / nice list - 75 entries

Christmas is here and Santa hasn't decided who's naughty or nice yet. He's given a list of names to his programmer friend to quickly split the children into naughty and nice. Hint: There's a hidden pattern that might be familiar.

  • Best score: 39
  • Best player score: 93
  • Position: #22 / 22
  • Number of attempts: 1
SFD-ROC: Tic-Tac-Toe - 131 entries

Tic-Tac-Toe You are 'X', and it is your turn. Stop 'O' from winning, and complete the game. Draw a diagonal line through your winning row of three X's.

  • Best score: 25
  • Best player score: 34
  • Position: #28 / 49
  • Number of attempts: 8
pankaj singh
Twitter:

entered into 26 challenges

contributed 0 challenges