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

Prime Numbers - 374 entries

List the first 100 prime numbers.

  • Best score: 34
  • Best player score: 96
  • Position: #81 / 105
  • Number of attempts: 2
replacing each line of a block selection - 2999 entries

replace each line's ../assets/js with /javascripts

  • Best score: 18
  • Best player score: 21
  • Position: #322 / 777
  • Number of attempts: 1
constructor - 182 entries

coding a constructor for a simple class

  • Best score: 59
  • Best player score: 124
  • Position: #44 / 60
  • Number of attempts: 2
switch variable - 5071 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 11
  • Position: #56 / 1748
  • Number of attempts: 3
Ugly spreadsheet copy/paste to CSV - 1009 entries

convert an ugly spreadsheet copy/paste into a CSV format.

  • Best score: 19
  • Best player score: 42
  • Position: #126 / 193
  • Number of attempts: 2
Replacing some words - 428 entries

How fast could it be?

  • Best score: 17
  • Best player score: 21
  • Position: #76 / 151
  • Number of attempts: 2
Sort the cardinal numbers - 310 entries

Maybe a simple challenge.

  • Best score: 12
  • Best player score: 14
  • Position: #107 / 148
  • Number of attempts: 1
Make it more readable - 2005 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 15
  • Position: #222 / 650
  • Number of attempts: 4
Line Zipper - 473 entries

Zip/pair related lines.

  • Best score: 12
  • Best player score: 16
  • Position: #161 / 215
  • 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: #50 / 101
  • Number of attempts: 3
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: 21
  • Position: #101 / 180
  • 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: 26
  • Position: #45 / 69
  • Number of attempts: 1
imports alignment (python) - 700 entries

Align as one import per line.

  • Best score: 17
  • Best player score: 19
  • Position: #61 / 198
  • Number of attempts: 3
Overall Vimgolf Rank - 216 entries

Suppose you are trying to figure out what your overall rank is at Vimgolf(the sum of all the ranks you got), and as a Vim ninja you decided to use Vim to do the job. Your solution should work for every Vimgolf profile page(The actual input file for this challenge is my Vimgolf profile page). So, direct answer insertion is considered cheating.

  • Best score: 21
  • Best player score: 27
  • Position: #27 / 59
  • Number of attempts: 9
Numbering a List - 1931 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 20
  • Position: #301 / 652
  • Number of attempts: 2
Java Array2List - 233 entries

Convert an java array initializer into a list.

  • Best score: 67
  • Best player score: 88
  • Position: #30 / 87
  • Number of attempts: 2
Assignment Alignment - 883 entries

line up the operators. Use spaces, not tabs.

  • Best score: 18
  • Best player score: 25
  • Position: #119 / 220
  • Number of attempts: 1
Shebangs for all - 1999 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: 13
  • Position: #189 / 516
  • Number of attempts: 5
82 bottles of beer on the wall - 313 entries

Take them down. (sorry, only 82 bottles because the problem size is limited!)

  • Best score: 106
  • Best player score: 121
  • Position: #45 / 146
  • Number of attempts: 1
Reverse and count - 473 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: 29
  • Position: #114 / 176
  • Number of attempts: 1
Another Mixed-Up Haiku - 265 entries

VimGolf ... a perfect evening?

  • Best score: 21
  • Best player score: 24
  • Position: #51 / 90
  • Number of attempts: 1
Reverse Simple Deletion - 847 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 15
  • Position: #415 / 458
  • Number of attempts: 1
The Cake is a Lie - 1346 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 10
  • Position: #336 / 527
  • Number of attempts: 1
Remember FizzBuzz? - 725 entries

Output FizzBuzz to 100. Start with nothing.

  • Best score: 39
  • Best player score: 61
  • Position: #116 / 190
  • Number of attempts: 1
Kurt Gaastra
Twitter:

entered into 24 challenges

contributed 0 challenges