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

Quicksort - 2005 entries

We need the numbers in the first row sorted as quickly as possible! Be careful not to disturb the data below the divider though: that must remain unchanged.

  • Best score: 6
  • Best player score: 6
  • Position: #104 / 442
  • Number of attempts: 8
Poorly indented Python comments - 1316 entries

Fix the alignment of some Python comments as quickly as possible.

  • Best score: 15
  • Best player score: 23
  • Position: #88 / 222
  • Number of attempts: 17
Fix the shell script! - 2596 entries

Fix the shell script with the fewest keystrokes!

  • Best score: 26
  • Best player score: 39
  • Position: #397 / 603
  • Number of attempts: 2
Inverting Lines - 1907 entries

A simple challenge to invert all lines, except the first.

  • Best score: 10
  • Best player score: 13
  • Position: #349 / 512
  • Number of attempts: 4
Modernise code - 1402 entries

Modernise and clean up some C++ code.

  • Best score: 34
  • Best player score: 60
  • Position: #288 / 324
  • Number of attempts: 2
Rural Post - 4547 entries

Simple challenge to remove all but the post code on each line

  • Best score: 9
  • Best player score: 10
  • Position: #473 / 1109
  • Number of attempts: 6
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: 24
  • Position: #3119 / 7447
  • Number of attempts: 6
Swap values - 4643 entries

Well, swap the values...

  • Best score: 11
  • Best player score: 12
  • Position: #525 / 1274
  • Number of attempts: 4
prepend * to every non-blank line - 6352 entries

Prepend an asterisk to every non-blank line in the input file.

  • Best score: 10
  • Best player score: 15
  • Position: #1004 / 1548
  • Number of attempts: 3
V to the i - 4818 entries

Input is 99 V's. Output is 100 i's.

  • Best score: 7
  • Best player score: 7
  • Position: #792 / 1898
  • Number of attempts: 2
Applying same text modification in several lines - 2897 entries

Remove identical text at the beginning of several lines and the closing parenthesis.

  • Best score: 12
  • Best player score: 14
  • Position: #495 / 857
  • Number of attempts: 5
Add semicolons - 10887 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 12
  • Position: #1961 / 3074
  • Number of attempts: 4
Split line with dots - 2154 entries

This line is too long, split it.

  • Best score: 15
  • Best player score: 22
  • Position: #473 / 635
  • Number of attempts: 1
remove lines containing the word "reader" - 3604 entries

easy stuff

  • Best score: 9
  • Best player score: 9
  • Position: #495 / 1169
  • Number of attempts: 4
Com(m)a Trouble - 3880 entries

Someone was real stupid when placing his commas. Can you fix it?

  • Best score: 12
  • Best player score: 16
  • Position: #518 / 878
  • Number of attempts: 6
Box it - 7916 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 22
  • Position: #554 / 1881
  • Number of attempts: 9
Search and Replace 0 - 5004 entries

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

  • Best score: 12
  • Best player score: 12
  • Position: #718 / 1630
  • Number of attempts: 3
That hyphen - 2595 entries

"vim vi improved"

  • Best score: 9
  • Best player score: 11
  • Position: #379 / 701
  • Number of attempts: 5
Make HTML List - 1061 entries

Turn the comma separated list into an unordered html list.

  • Best score: 33
  • Best player score: 39
  • Position: #89 / 274
  • Number of attempts: 12
Vice versa - 7952 entries

Little role switching.

  • Best score: 12
  • Best player score: 12
  • Position: #616 / 2139
  • Number of attempts: 12
One to Ten - 2227 entries

Generate the sequence of numbers from 1 to 10, one number per line. Inspired by this Reddit thread: https://redd.it/ak4it2

  • Best score: 12
  • Best player score: 12
  • Position: #357 / 677
  • Number of attempts: 12
Array transposition - 2425 entries

Transpose two arrays into one.

  • Best score: 16
  • Best player score: 17
  • Position: #173 / 449
  • Number of attempts: 13
I forgot quotes - 16038 entries

Oops.

  • Best score: 10
  • Best player score: 14
  • Position: #2042 / 4192
  • Number of attempts: 4
A HAPPY NEW YEAR 2014 ! - 10688 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 11
  • Position: #1603 / 3691
  • Number of attempts: 5
switch variable - 5079 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 12
  • Position: #1007 / 1749
  • Number of attempts: 3
Whitespace, empty lines and tabs - 3763 entries

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

  • Best score: 16
  • Best player score: 18
  • Position: #187 / 807
  • Number of attempts: 10
Simple text editing with Vim - 13012 entries

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

  • Best score: 13
  • Best player score: 35
  • Position: #3529 / 3743
  • Number of attempts: 1
Reformat/Refactor a Golfer Class - 7172 entries

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

  • Best score: 28
  • Best player score: 37
  • Position: #583 / 1760
  • Number of attempts: 5
rayx
Github:

entered into 28 challenges

contributed 0 challenges