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 - 33621 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: #1324 / 7422
  • Number of attempts: 3
One number per line - 18732 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 16
  • Position: #954 / 3865
  • Number of attempts: 4
V to the i - 4806 entries

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

  • Best score: 7
  • Best player score: 7
  • Position: #481 / 1894
  • Number of attempts: 3
Applying same text modification in several lines - 2880 entries

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

  • Best score: 12
  • Best player score: 13
  • Position: #160 / 851
  • Number of attempts: 4
Add semicolons - 10860 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 10
  • Position: #14 / 3064
  • Number of attempts: 7
Box it - 7906 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 21
  • Position: #107 / 1877
  • Number of attempts: 4
Every other line - 2910 entries

AaAaAaA

  • Best score: 12
  • Best player score: 16
  • Position: #392 / 703
  • Number of attempts: 2
Copy three lines - 2872 entries

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

  • Best score: 13
  • Best player score: 16
  • Position: #260 / 640
  • Number of attempts: 4
Search and Replace 0 - 4989 entries

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

  • Best score: 12
  • Best player score: 13
  • Position: #856 / 1624
  • Number of attempts: 2
Just the middle - 11457 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #2422 / 4198
  • Number of attempts: 2
Make HTML List - 1050 entries

Turn the comma separated list into an unordered html list.

  • Best score: 33
  • Best player score: 39
  • Position: #85 / 273
  • Number of attempts: 2
Format java properties - 88 entries

Format java properties to a different format. The value which is the string following the first '=' cannot & should not change. All periods in the key get replaced with an underscore "_" and get a prefix of "b_".

  • Best score: 27
  • Best player score: 36
  • Position: #25 / 35
  • Number of attempts: 2
Basic renumbering - 5648 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 18
  • Position: #682 / 1264
  • Number of attempts: 3
Combines all items - 313 entries

For each line that starts with the same number I want to combine its contents

  • Best score: 9
  • Best player score: 10
  • Position: #119 / 140
  • Number of attempts: 1
C Reformatting - 690 entries

You may use Visual mode... or not. #uppercase

  • Best score: 30
  • Best player score: 56
  • Position: #108 / 163
  • Number of attempts: 2
Order and join - 983 entries

There's something special about the input order.

  • Best score: 10
  • Best player score: 13
  • Position: #184 / 259
  • Number of attempts: 3
Scrambled numbers - 807 entries

Four is NOT 1. One is 1.

  • Best score: 18
  • Best player score: 23
  • Position: #98 / 184
  • Number of attempts: 4
Collect List - 4298 entries

Convert to comma separated list.

  • Best score: 12
  • Best player score: 12
  • Position: #303 / 1190
  • Number of attempts: 3
camel riding - 793 entries

add a prefix on some camelCase variables

  • Best score: 15
  • Best player score: 15
  • Position: #58 / 281
  • Number of attempts: 3
Space out the alphabet - 1657 entries

Put 3 spaces between adjacent letters.

  • Best score: 15
  • Best player score: 18
  • Position: #226 / 444
  • Number of attempts: 1
Conway sequence - 26 entries

Generate the the first fifteen numbers. See here for more information: http://en.wikipedia.org/wiki/Look-and-say_sequence

  • Best score: 43
  • Best player score: 43
  • Position: #13 / 20
  • Number of attempts: 1
-a-b-c- - 3213 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 17
  • Position: #980 / 1137
  • Number of attempts: 1
Count both ways - 1022 entries

Right AND down.

  • Best score: 13
  • Best player score: 16
  • Position: #264 / 354
  • Number of attempts: 2
Do you demand a shrubbery? - 1158 entries

Use :redir and crush the emacsgolfers.

  • Best score: 15
  • Best player score: 15
  • Position: #59 / 300
  • Number of attempts: 3
Saving the hashes(#) - 2063 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: 29
  • Position: #350 / 480
  • Number of attempts: 1
Simple text editing with Vim - 12815 entries

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

  • Best score: 13
  • Best player score: 14
  • Position: #1590 / 3696
  • Number of attempts: 2
Jerry Wu
Twitter:

People are like snowflakes: Piles of them on the road make it hard to drive.

entered into 26 challenges

contributed 0 challenges