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

Wrap the text of an email message to 79 characters - 750 entries

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

  • Best score: 5
  • Best player score: 5
  • Position: #73 / 405
  • Number of attempts: 1
Interweave two blocks of text - 658 entries

Suppose you've got data on a list of things from multiple sources. They're all in separate chunks, so how might you create a tabular output?

  • Best score: 15
  • Best player score: 17
  • Position: #100 / 213
  • Number of attempts: 3
switch variable - 5061 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 22
  • Position: #1679 / 1743
  • Number of attempts: 1
PHP <--> Java class conversion Part 1 - 254 entries

Convert this tiny php class to adequate java one.

  • Best score: 65
  • Best player score: 137
  • Position: #51 / 63
  • Number of attempts: 1
formatted text to markdown - 184 entries

You're converting some posts from an old blog to markdown. The formatted text is far closer to the finished product than the html markup, so it seems like a good place to start. Word wrapping seems to be the main area for optimization.

  • Best score: 70
  • Best player score: 74
  • Position: #9 / 67
  • Number of attempts: 7
Line Zipper - 471 entries

Zip/pair related lines.

  • Best score: 12
  • Best player score: 13
  • Position: #24 / 213
  • Number of attempts: 4
PHP <--> Java class conversion Part 2 - 98 entries

Same class but reverse!

  • Best score: 79
  • Best player score: 144
  • Position: #32 / 39
  • Number of attempts: 2
Alphabetize the directory - 298 entries

Put the contacts and their information in alphabetical order.

  • Best score: 30
  • Best player score: 34
  • Position: #44 / 101
  • Number of attempts: 4
Case preserving word replacement - 454 entries

Half way through my project, my people turned into dogs. Now I have to change everything in my source.

  • Best score: 19
  • Best player score: 19
  • Position: #26 / 180
  • Number of attempts: 3
Numbering a List - 1929 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 19
  • Position: #198 / 651
  • Number of attempts: 5
Java Array2List - 232 entries

Convert an java array initializer into a list.

  • Best score: 67
  • Best player score: 115
  • Position: #60 / 87
  • Number of attempts: 1
A Simple One - 1037 entries

Here is a very simple one - just to illustrate/introduce a vim feature that some people seem to miss...

  • Best score: 9
  • Best player score: 9
  • Position: #221 / 657
  • Number of attempts: 1
Reverse Simple Deletion - 845 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Position: #205 / 457
  • Number of attempts: 1
The Cake is a Lie - 1330 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 9
  • Position: #102 / 523
  • Number of attempts: 2
Almost encrypted - 204 entries

Convert the first paragraph to be even less readable.

  • Best score: 5
  • Best player score: 5
  • Position: #71 / 146
  • Number of attempts: 1
Remember FizzBuzz? - 712 entries

Output FizzBuzz to 100. Start with nothing.

  • Best score: 39
  • Best player score: 60
  • Position: #107 / 187
  • Number of attempts: 1
Change the content of a string - 1541 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 22
  • Position: #58 / 577
  • Number of attempts: 5
Sort and add attributes - 1418 entries

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

  • Best score: 33
  • Best player score: 33
  • Position: #76 / 551
  • Number of attempts: 3
Add fold markers to a .c file - 604 entries

Fold markers can make it easier to navigate source code. Add them to this .c file.

  • Best score: 30
  • Best player score: 35
  • Position: #95 / 179
  • Number of attempts: 2
Reconstruct the Sentence - 1467 entries

Get the sentence back in the proper order, remove duplicate lines, and then combine the separate lines into one.

  • Best score: 20
  • Best player score: 20
  • Position: #29 / 403
  • Number of attempts: 5
Braces or Brackets? - 957 entries

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

  • Best score: 34
  • Best player score: 48
  • Position: #192 / 306
  • Number of attempts: 2
Whitespace, empty lines and tabs - 3568 entries

Convert tabs to spaces, strip empty lines and trailing whitespace.

  • Best score: 16
  • Best player score: 26
  • Position: #405 / 770
  • Number of attempts: 3
Flodder-challenge - 1219 entries

Replace the text the most efficient and win!

  • Best score: 27
  • Best player score: 37
  • Position: #189 / 327
  • Number of attempts: 4
Simple text editing with Vim - 12627 entries

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

  • Best score: 13
  • Best player score: 23
  • Position: #2959 / 3653
  • Number of attempts: 2
Reformat/Refactor a Golfer Class - 6825 entries

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

  • Best score: 28
  • Best player score: 44
  • Position: #1064 / 1673
  • Number of attempts: 2
Simon Scarfe
Twitter:

Help make websites at BBC. Streak Runner. Dickhead. Words, opinions, and swear words are all mine. Obviously.

entered into 25 challenges

contributed 0 challenges