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 - 33616 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: #1342 / 7420
  • Number of attempts: 2
Wrap the text of an email message to 79 characters - 766 entries

You're replying to an email with silly long lines. Clean them up.

  • Best score: 5
  • Best player score: 5
  • Position: #39 / 410
  • Number of attempts: 1
That hyphen - 2595 entries

"vim vi improved"

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

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 7
  • Position: #244 / 4197
  • Number of attempts: 2
C Reformatting - 690 entries

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

  • Best score: 30
  • Best player score: 30
  • Position: #1 / 163
  • Number of attempts: 1
camel riding - 793 entries

add a prefix on some camelCase variables

  • Best score: 15
  • Best player score: 16
  • Position: #99 / 281
  • Number of attempts: 4
readability - 327 entries

Make the code readable by adding some spaces

  • Best score: 18
  • Best player score: 18
  • Position: #15 / 152
  • Number of attempts: 1
remove all lines in first part - 211 entries

From the second part, remove all lines in the first part. It can be useful when you have done something from a long list, you want to know what is not done yet!

  • Best score: 13
  • Best player score: 15
  • Position: #24 / 67
  • Number of attempts: 1
Shuffled numbers - 246 entries

Each number is paired with the number it should follow. That's enough information to put them in order.

  • Best score: 15
  • Best player score: 16
  • Position: #57 / 96
  • Number of attempts: 1
Mute the second method of this script - 455 entries

prepend a # infront of every line of the second method

  • Best score: 8
  • Best player score: 9
  • Position: #83 / 239
  • Number of attempts: 1
I forgot quotes - 15983 entries

Oops.

  • Best score: 10
  • Best player score: 14
  • Position: #1545 / 4180
  • Number of attempts: 1
-a-b-c- - 3213 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 13
  • Position: #95 / 1137
  • Number of attempts: 1
Don't know what this is - 2022 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: 12
  • Position: #185 / 585
  • Number of attempts: 2
Words in parens - 12935 entries

We should all ace this, right?

  • Best score: 13
  • Best player score: 14
  • Position: #543 / 3963
  • Number of attempts: 3
SFD-ROC: vimvimvim - 1606 entries

Oh no, this line is longer than 80 chars... put each 'vim' on a new line.

  • Best score: 8
  • Best player score: 9
  • Position: #236 / 446
  • Number of attempts: 1
imports alignment (python) - 700 entries

Align as one import per line.

  • Best score: 17
  • Best player score: 17
  • Position: #9 / 198
  • Number of attempts: 5
Generate English Alphabets - 487 entries

Start with a, get up to z.

  • Best score: 19
  • Best player score: 25
  • Position: #98 / 206
  • Number of attempts: 1
The holy-grail may help - 366 entries

Can you find it in less than 20 strokes, Arthur?

  • Best score: 16
  • Best player score: 16
  • Position: #67 / 209
  • Number of attempts: 1
Table Reshuffle - 429 entries

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

  • Best score: 22
  • Best player score: 23
  • Position: #12 / 139
  • 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: #182 / 458
  • Number of attempts: 1
The Cake is a Lie - 1346 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 9
  • Position: #86 / 527
  • Number of attempts: 1
Braces or Brackets? - 1015 entries

Someone forgot whether to use braces or brackets and you have to clean up their code!

  • Best score: 34
  • Best player score: 35
  • Position: #43 / 315
  • Number of attempts: 1
Simple text editing with Vim - 12811 entries

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

  • Best score: 13
  • Best player score: 13
  • Position: #1 / 3694
  • Number of attempts: 2
Reformat/Refactor a Golfer Class - 6982 entries

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

  • Best score: 28
  • Best player score: 35
  • Position: #329 / 1706
  • Number of attempts: 1
Antony Scriven
Twitter:

entered into 24 challenges

contributed 0 challenges