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

Rural Post - 3727 entries

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

  • Best score: 9
  • Best player score: 10
  • Position: #370 / 918
  • Number of attempts: 1
xrandr outputs and dashes - 523 entries

uh oh, different video drivers identify display outputs with more dashes. Quick, need to change this xrandr script!

  • Best score: 12
  • Best player score: 12
  • Position: #23 / 173
  • Number of attempts: 1
Simple, Practical, and Common - 32746 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: 23
  • Position: #2638 / 7235
  • Number of attempts: 1
prepend * to every non-blank line - 5776 entries

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

  • Best score: 10
  • Best player score: 11
  • Position: #529 / 1421
  • Number of attempts: 1
One number per line - 18240 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 17
  • Position: #1216 / 3760
  • Number of attempts: 2
Aliases for cd - 781 entries

Create these beautiful aliases with as few strokes as possible. Are you up for the challenge?

  • Best score: 30
  • Best player score: 39
  • Position: #46 / 142
  • Number of attempts: 1
Swap values inside brackets - 2404 entries

Easy challenge.

  • Best score: 14
  • Best player score: 16
  • Position: #243 / 555
  • Number of attempts: 1
Add semicolons - 10429 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 11
  • Position: #1012 / 2954
  • Number of attempts: 1
Bad Copy Syntax - 1882 entries

Copy should be from right to left, but sometimes you type it wrong.

  • Best score: 18
  • Best player score: 19
  • Position: #140 / 478
  • Number of attempts: 1
From argument to object - 1250 entries

This task typifies those programmers endure while coding. This C-family pseudocode needs a function argument to be repurposed as an object call. Simply search and replace? Repeat a pattern of edits?

  • Best score: 17
  • Best player score: 18
  • Position: #227 / 412
  • Number of attempts: 1
comment and uncomment code inline - 974 entries

It's very useful to be able to comment out a block of code in a quick edit. And likewise to uncomment the code. This operation often involves multi-line stanzas and even large blocks. With just line-wise navigation and insert mode this would cost you about 4 keystrokes per line. Master this hole of VimGolf and you'll quickly drop your key count in day to day Vim as well.

  • Best score: 9
  • Best player score: 10
  • Position: #188 / 290
  • Number of attempts: 1
Just the middle - 11074 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #2863 / 4088
  • Number of attempts: 1
Team names - 1754 entries

The team names are misspelled.

  • Best score: 16
  • Best player score: 16
  • Position: #249 / 564
  • Number of attempts: 1
Interweave two blocks of text - 530 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: 16
  • Position: #51 / 196
  • Number of attempts: 1
Basic renumbering - 5393 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 11
  • Position: #199 / 1218
  • Number of attempts: 1
Sudoku table - 58 entries

Make this simple sudoku table look nice and legible.

  • Best score: 48
  • Best player score: 50
  • Position: #8 / 27
  • Number of attempts: 1
Python challenge - 128 entries

Change the types of the variables in the list from str to float, while keeping the truncation.

  • Best score: 31
  • Best player score: 32
  • Position: #8 / 39
  • Number of attempts: 1
Increment each number - 922 entries

Increment each number individually by one

  • Best score: 15
  • Best player score: 19
  • Position: #107 / 228
  • Number of attempts: 1
-a-b-c- - 3077 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 15
  • Position: #695 / 1099
  • Number of attempts: 1
120 Degrees - 399 entries

Rotate that triangle.

  • Best score: 14
  • Best player score: 15
  • Position: #32 / 135
  • Number of attempts: 1
A HAPPY NEW YEAR 2014 ! - 10507 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 12
  • Position: #2383 / 3626
  • Number of attempts: 1
NATO phonetic alphabet - 438 entries

Transform the series of words into a list.

  • Best score: 19
  • Best player score: 19
  • Position: #42 / 167
  • Number of attempts: 2
Context insensitive completion 0 - 461 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: 6
  • Position: #1 / 216
  • Number of attempts: 1
Reverse characters in a line - 613 entries

You have everything you need, just not in the right order. Mastermind would give you 26 white pegs.

  • Best score: 12
  • Best player score: 13
  • Position: #72 / 225
  • Number of attempts: 2
vimRunnerUp3000
Twitter:

I'm a vim runner up

entered into 24 challenges

contributed 0 challenges