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 - 799 entries

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

  • Best score: 5
  • Best player score: 5
  • Position: #74 / 421
  • Number of attempts: 1
Search and Replace 0 - 5004 entries

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

  • Best score: 12
  • Best player score: 12
  • Position: #133 / 1630
  • Number of attempts: 5
Interweave two blocks of text - 661 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: #102 / 215
  • Number of attempts: 3
Alphabetize the directory - 298 entries

Put the contacts and their information in alphabetical order.

  • Best score: 30
  • Best player score: 38
  • Position: #62 / 101
  • Number of attempts: 2
Complete the hex array data (Part II) - 166 entries

Do not use external tools(e.g. tac, seq) [My interpretation of Rule #7]

  • Best score: 20
  • Best player score: 22
  • Position: #23 / 69
  • Number of attempts: 4
imports alignment (python) - 700 entries

Align as one import per line.

  • Best score: 17
  • Best player score: 20
  • Position: #79 / 198
  • Number of attempts: 1
It'ss tooo coold too typpe todaay - 230 entries

My hands are numb with cold. It's hard to type correctly.

  • Best score: 16
  • Best player score: 18
  • Position: #34 / 99
  • Number of attempts: 2
Rotating Philosophers Problem - 410 entries

Can you help the philosophers find a good place to sit before they get five forks and spaghetti?

  • Best score: 29
  • Best player score: 30
  • Position: #61 / 166
  • Number of attempts: 4
expand a list comprehension (python) - 334 entries

Please show your way to convert a list comprehension in python to an ordinary for-loop expression!

  • Best score: 42
  • Best player score: 51
  • Position: #44 / 110
  • Number of attempts: 1
Reformat long lines - 361 entries

Rearrange this ruby method call to put each parameter on its own line. Could become a useful macro.

  • Best score: 15
  • Best player score: 15
  • Position: #8 / 135
  • Number of attempts: 3
Generate English Alphabets - 487 entries

Start with a, get up to z.

  • Best score: 19
  • Best player score: 25
  • Position: #106 / 206
  • Number of attempts: 2
Numbering a List - 1935 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 24
  • Position: #473 / 654
  • Number of attempts: 1
Solve the Sokoban - 177 entries

A wink for all Vimgolfers that play Nethack too.

  • Best score: 25
  • Best player score: 31
  • Position: #46 / 74
  • Number of attempts: 2
Java Array2List - 233 entries

Convert an java array initializer into a list.

  • Best score: 67
  • Best player score: 120
  • Position: #67 / 87
  • Number of attempts: 1
The holy-grail may help - 377 entries

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

  • Best score: 16
  • Best player score: 16
  • Position: #95 / 212
  • Number of attempts: 2
Ruby 1.9 hashes - 1249 entries

Rubyists talk about being cutting edge but how many are using 1.9 in production? Time to convert those verbose 1.8 hashes in to symbolic, succinct 1.9 beauties!

  • Best score: 12
  • Best player score: 13
  • Position: #148 / 407
  • Number of attempts: 2
A Simple One - 1057 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: #222 / 667
  • Number of attempts: 1
Table Reshuffle - 439 entries

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

  • Best score: 22
  • Best player score: 29
  • Position: #61 / 142
  • Number of attempts: 2
Reverse and count - 480 entries

Someone typed things upside down and now a Vim ninja needs to reverse the lines and count how many there are.

  • Best score: 18
  • Best player score: 26
  • Position: #102 / 178
  • Number of attempts: 2
Reverse Simple Deletion - 854 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Position: #207 / 460
  • Number of attempts: 1
Increment, increment, increment.... - 692 entries

Vim likes macros

  • Best score: 10
  • Best player score: 12
  • Position: #213 / 410
  • Number of attempts: 1
Indentation - 550 entries

Indent each line according to the right number of spaces it needs.

  • Best score: 20
  • Best player score: 28
  • Position: #90 / 180
  • Number of attempts: 2
The Cake is a Lie - 1361 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 9
  • Position: #103 / 531
  • Number of attempts: 2
Make Fancy Header - 1063 entries

Make the header text stand out with surrounding asterisks

  • Best score: 15
  • Best player score: 16
  • Position: #45 / 346
  • Number of attempts: 4
Sort and add attributes - 1477 entries

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

  • Best score: 33
  • Best player score: 33
  • Position: #77 / 575
  • Number of attempts: 3
Add fold markers to a .c file - 660 entries

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

  • Best score: 30
  • Best player score: 36
  • Position: #109 / 189
  • Number of attempts: 1
Reconstruct the Sentence - 1589 entries

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

  • Best score: 19
  • Best player score: 20
  • Position: #35 / 425
  • Number of attempts: 2
Braces or Brackets? - 1054 entries

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

  • Best score: 34
  • Best player score: 38
  • Position: #74 / 324
  • Number of attempts: 6
Simple text editing with Vim - 12989 entries

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

  • Best score: 13
  • Best player score: 14
  • Position: #897 / 3737
  • Number of attempts: 2
Jesús Espino
Twitter:

Apasionado del software libre.

entered into 29 challenges

contributed 0 challenges