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 - 33617 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: 24
  • Position: #2823 / 7421
  • Number of attempts: 3
Split line with dots - 2144 entries

This line is too long, split it.

  • Best score: 15
  • Best player score: 22
  • Position: #447 / 634
  • Number of attempts: 1
That hyphen - 2595 entries

"vim vi improved"

  • Best score: 9
  • Best player score: 13
  • Position: #507 / 701
  • Number of attempts: 1
Just the middle - 11454 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #1802 / 4197
  • Number of attempts: 6
Basic renumbering - 5648 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 18
  • Position: #652 / 1264
  • Number of attempts: 2
Restore order to the alphabet - 201 entries

The numbers are OK. The letters are wonky.

  • Best score: 12
  • Best player score: 13
  • Position: #24 / 72
  • Number of attempts: 3
Swap assigned value - 647 entries

Simple problem but looking for interesting solutions.

  • Best score: 10
  • Best player score: 10
  • Position: #75 / 254
  • Number of attempts: 2
VimGolfNight - 560 entries

Based on "The name of the game".

  • Best score: 12
  • Best player score: 12
  • Position: #218 / 347
  • Number of attempts: 1
swap or reverse - 126 entries

Try to swap or reverse the line as needed.

  • Best score: 16
  • Best player score: 18
  • Position: #61 / 69
  • Number of attempts: 2
Space out the alphabet - 1657 entries

Put 3 spaces between adjacent letters.

  • Best score: 15
  • Best player score: 27
  • Position: #404 / 444
  • Number of attempts: 1
Condensed Cases - 804 entries

Apple's new programming language, Swift, allows two style of case statements: 1) one Enum case on each line, or 2) multiple Enum cases on a single line. Convert the following from the first case (no pun intended) to the second type.

  • Best score: 12
  • Best player score: 22
  • Position: #228 / 247
  • Number of attempts: 1
-a-b-c- - 3213 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 15
  • Position: #562 / 1137
  • Number of attempts: 2
Change name of a variable - 179 entries

Replace the name of the $variable with the fastest move possible. The challenge is having a command that allow you to easily change the variable name even if its indented.

  • Best score: 9
  • Best player score: 9
  • Position: #91 / 137
  • Number of attempts: 1
120 Degrees - 493 entries

Rotate that triangle.

  • Best score: 14
  • Best player score: 14
  • Position: #22 / 145
  • Number of attempts: 5
Words in parens - 12935 entries

We should all ace this, right?

  • Best score: 13
  • Best player score: 16
  • Position: #2235 / 3963
  • Number of attempts: 5
Prefixes and suffixes - 635 entries

Generate all prefixes of "vimchallenge", then all suffixes.

  • Best score: 17
  • Best player score: 28
  • Position: #127 / 201
  • Number of attempts: 1
Let's play some Ivmgolf - 1118 entries

Oops, I spelled that wrong.

  • Best score: 7
  • Best player score: 7
  • Position: #81 / 445
  • Number of attempts: 2
Remove semicolons after expressions - 654 entries

A follow-up for http://vimgolf.com/challenges/4fc9d767d3a0d4000100000e.

  • Best score: 6
  • Best player score: 8
  • Position: #219 / 263
  • Number of attempts: 2
The meaning - 575 entries

Numbers are fun!

  • Best score: 5
  • Best player score: 5
  • Position: #249 / 363
  • Number of attempts: 1
Ugly spreadsheet copy/paste to CSV - 1009 entries

convert an ugly spreadsheet copy/paste into a CSV format.

  • Best score: 19
  • Best player score: 36
  • Position: #116 / 193
  • Number of attempts: 2
Table Reshuffle - 429 entries

Fix the column order in this table... also append the new 'username' column.

  • Best score: 22
  • Best player score: 36
  • Position: #93 / 139
  • Number of attempts: 1
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: 17
  • Position: #150 / 234
  • Number of attempts: 1
Reverse Simple Deletion - 847 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Position: #310 / 458
  • Number of attempts: 1
Reverse characters in a line - 771 entries

You have everything you need, just not in the right order. Mastermind would give you 26 white pegs.

  • Best score: 12
  • Best player score: 15
  • Position: #142 / 265
  • Number of attempts: 5
Adrien Fabre
Twitter:

entered into 24 challenges

contributed 0 challenges