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 - 33742 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: 35
  • Position: #6601 / 7447
  • Number of attempts: 1
One number per line - 18776 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 32
  • Position: #3702 / 3875
  • Number of attempts: 1
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: 8
  • Position: #383 / 421
  • Number of attempts: 2
Box it - 7916 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 34
  • Position: #1575 / 1881
  • Number of attempts: 1
Search and Replace 0 - 5004 entries

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

  • Best score: 12
  • Best player score: 22
  • Position: #1546 / 1630
  • Number of attempts: 4
Python Hello World! Reformatting - 1000 entries

A novice Python using prints Hello World! and a pro shows him different way. Using vim to get into pro style from novice, win the challenge.

  • Best score: 39
  • Best player score: 49
  • Position: #336 / 382
  • Number of attempts: 2
I forgot quotes - 16038 entries

Oops.

  • Best score: 10
  • Best player score: 20
  • Position: #3661 / 4192
  • Number of attempts: 2
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: 23
  • Position: #52 / 99
  • Number of attempts: 1
Shebangs for all - 2018 entries

We've all seen or used a shebang once or twice. Ditch the specific paths and leave just a dynamic Ruby and Python bath behind.

  • Best score: 11
  • Best player score: 25
  • Position: #479 / 519
  • 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: 55
  • Position: #173 / 178
  • Number of attempts: 1
Ruby 1.9 compat - 634 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: 22
  • Position: #216 / 235
  • Number of attempts: 1
Increment, increment, increment.... - 696 entries

Vim likes macros

  • Best score: 10
  • Best player score: 13
  • Position: #380 / 411
  • Number of attempts: 1
Context insensitive completion 0 - 585 entries

Buried in the lines you're not supposed to add is the line "Add this line!" Add that line to the top of the file.

  • Best score: 6
  • Best player score: 10
  • Position: #215 / 248
  • Number of attempts: 4
Reformat some Python - 622 entries

Fix some very bizarrely laid-out code.

  • Best score: 34
  • Best player score: 64
  • Position: #213 / 238
  • Number of attempts: 1
Change the content of a string - 1596 entries

This docstring is a complete lie. Fix it.

  • Best score: 22
  • Best player score: 28
  • Position: #506 / 595
  • 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: 42
  • Position: #548 / 575
  • Number of attempts: 2
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: 30
  • Position: #390 / 425
  • Number of attempts: 2
Flodder-challenge - 1343 entries

Replace the text the most efficient and win!

  • Best score: 27
  • Best player score: 53
  • Position: #322 / 348
  • Number of attempts: 1
Jan B.
Twitter:

co-founder @superluminario, ⛅️-consulting, https://t.co/h4IxIYLYdk

entered into 18 challenges

contributed 0 challenges