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

HS exam question - 1599 entries

Convert the data to a python dictionary

  • Best score: 47
  • Best player score: 67
  • Position: #173 / 419
  • Number of attempts: 2
hello-world-vimgolf - 2513 entries

Simple number generation

  • Best score: 10
  • Best player score: 14
  • Position: #526 / 717
  • Number of attempts: 1
Python: Def to Lambda - 460 entries

LAMBDA!!!

  • Best score: 19
  • Best player score: 23
  • Position: #129 / 157
  • Number of attempts: 1
Yo To Hello - 1152 entries

Simply Turn Yo To Hello

  • Best score: 8
  • Best player score: 12
  • Position: #493 / 534
  • Number of attempts: 1
Simple, Practical, and Common - 33866 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: 27
  • Position: #3818 / 7474
  • Number of attempts: 2
One number per line - 18831 entries

Just give me the numbers.

  • Best score: 14
  • Best player score: 19
  • Position: #1619 / 3889
  • Number of attempts: 7
V to the i - 4830 entries

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

  • Best score: 7
  • Best player score: 9
  • Position: #1660 / 1903
  • Number of attempts: 2
Split line with dots - 2156 entries

This line is too long, split it.

  • Best score: 15
  • Best player score: 16
  • Position: #165 / 636
  • Number of attempts: 3
Copy three lines - 2882 entries

If the site is up (by some miracle), make the text under every header identical.

  • Best score: 13
  • Best player score: 20
  • Position: #397 / 642
  • Number of attempts: 1
That hyphen - 2602 entries

"vim vi improved"

  • Best score: 9
  • Best player score: 12
  • Position: #455 / 704
  • Number of attempts: 1
Just the middle - 11541 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #2190 / 4230
  • Number of attempts: 1
Interactive git rebase changing commands - 176 entries

How to change the action of some commits in git rebase dialog.

  • Best score: 14
  • Best player score: 16
  • Position: #62 / 80
  • Number of attempts: 1
Adam's challenge - 1009 entries

Change both normal to bold and 4 by 2. Adam Wathan challenge this on twitter . He did it in 11 keystrokes on Sublime.

  • Best score: 18
  • Best player score: 19
  • Position: #106 / 276
  • Number of attempts: 4
Wrap text in quotes - 368 entries

All the blocks of text should be wrapped in quotation marks.

  • Best score: 16
  • Best player score: 27
  • Position: #112 / 122
  • Number of attempts: 2
Vice versa - 7974 entries

Little role switching.

  • Best score: 12
  • Best player score: 16
  • Position: #1294 / 2146
  • Number of attempts: 1
Free hyphen! - 176 entries

Just like "Inner hyphens", but I'm giving you a free hyphen to play with. Will your solution be any different?

  • Best score: 9
  • Best player score: 11
  • Position: #66 / 90
  • Number of attempts: 1
C Reformatting - 692 entries

You may use Visual mode... or not. #uppercase

  • Best score: 30
  • Best player score: 51
  • Position: #87 / 164
  • Number of attempts: 3
comments galore - 1073 entries

Basic comment reformatting

  • Best score: 10
  • Best player score: 10
  • Position: #166 / 429
  • Number of attempts: 2
lipsum lines - 278 entries

Convert a quoted block of text into strings in a list.

  • Best score: 28
  • Best player score: 33
  • Position: #62 / 95
  • Number of attempts: 2
Align commas - 1097 entries

There are 15,000 aligning challenges on vimgolf.com, and they're all exactly the same. I hope this one is a little different.

  • Best score: 11
  • Best player score: 22
  • Position: #227 / 247
  • Number of attempts: 2
Manual SQL - 160 entries

Change select and insert queries to simulate inserting a new record.

  • Best score: 48
  • Best player score: 66
  • Position: #31 / 50
  • Number of attempts: 2
Generate a list of numbers - 299 entries

Please generate list of numbers from 1 to 20.

  • Best score: 14
  • Best player score: 15
  • Position: #88 / 141
  • Number of attempts: 2
convert yml into java pojo field - 867 entries

How fast vim can create fields for java pojo i.e class declaration referring to a (simple) yml file

  • Best score: 29
  • Best player score: 35
  • Position: #185 / 230
  • Number of attempts: 2
Collect List - 4317 entries

Convert to comma separated list.

  • Best score: 12
  • Best player score: 16
  • Position: #817 / 1194
  • Number of attempts: 2
VimGolfNight - 575 entries

Based on "The name of the game".

  • Best score: 12
  • Best player score: 15
  • Position: #312 / 352
  • Number of attempts: 1
Space out the alphabet - 1659 entries

Put 3 spaces between adjacent letters.

  • Best score: 15
  • Best player score: 25
  • Position: #387 / 446
  • Number of attempts: 2
Fix the XML - 1039 entries

The challenge consists in having a valid xml from an incomplete source.

  • Best score: 18
  • Best player score: 25
  • Position: #166 / 290
  • Number of attempts: 2
ASCII box - 354 entries

Don't forget to fix typos!

  • Best score: 23
  • Best player score: 28
  • Position: #80 / 109
  • Number of attempts: 3
Happy TvvO - 427 entries

Don’t forget the past, learn from it. Happy New Year.

  • Best score: 12
  • Best player score: 12
  • Position: #112 / 206
  • Number of attempts: 1
I forgot quotes - 16093 entries

Oops.

  • Best score: 10
  • Best player score: 15
  • Position: #2160 / 4202
  • Number of attempts: 5
-a-b-c- - 3225 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 17
  • Position: #959 / 1140
  • Number of attempts: 1
Count both ways - 1022 entries

Right AND down.

  • Best score: 13
  • Best player score: 16
  • Position: #248 / 354
  • Number of attempts: 3
Lisp Condense - 460 entries

Reduce 4 cons selection operations down to one function call.

  • Best score: 13
  • Best player score: 17
  • Position: #135 / 158
  • Number of attempts: 1
Where should I put the Newline? - 883 entries

Help me put the newline.

  • Best score: 7
  • Best player score: 8
  • Position: #380 / 438
  • Number of attempts: 2
Vim tetris - 371 entries

Vim can play tetris too!

  • Best score: 21
  • Best player score: 29
  • Position: #77 / 104
  • Number of attempts: 3
Shuffle puzzle - 346 entries

Sort the lines in each indent group, and sort the groups. That's the pattern. Or just move lines around manually to get a better score.

  • Best score: 13
  • Best player score: 14
  • Position: #47 / 104
  • Number of attempts: 3
A HAPPY NEW YEAR 2014 ! - 10713 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 15
  • Position: #3125 / 3700
  • Number of attempts: 2
Letter case trickery - 1644 entries

This file is in a downright esoteric format, consisting of hexadecimal numbers, non-hexadecimal keywords, and "Z" indicating end-of-line. Make the hexadecimal numbers lowercase.

  • Best score: 9
  • Best player score: 13
  • Position: #409 / 520
  • Number of attempts: 2
The name of the game - 678 entries

End up with the name of the game.

  • Best score: 11
  • Best player score: 11
  • Position: #212 / 363
  • Number of attempts: 3
Vertical Limit - 2596 entries

transform a succession of one word lines to a an array of strings

  • Best score: 21
  • Best player score: 26
  • Position: #482 / 767
  • Number of attempts: 2
Remove noise from HTTP log - 729 entries

This piece of log (from the year 2000) contains some irrelevant data. We only want to see the HTTP method and resource.

  • Best score: 15
  • Best player score: 19
  • Position: #246 / 276
  • Number of attempts: 1
The meaning - 577 entries

Numbers are fun!

  • Best score: 5
  • Best player score: 5
  • Position: #259 / 364
  • Number of attempts: 1
Ruby 1.9 hashes - 1272 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: 15
  • Position: #284 / 412
  • Number of attempts: 1
Reconstruct the Sentence - 1677 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: 22
  • Position: #282 / 440
  • Number of attempts: 1
Simple text editing with Vim - 13262 entries

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

  • Best score: 13
  • Best player score: 16
  • Position: #2322 / 3810
  • Number of attempts: 2
mattp (part of the πŸ’‰πŸ’‰πŸ’‰ club)
Twitter:

Greying, limping Esperantist. Topics include: languages, bellringing, maths, software, and cats. (Links occasionally NSFW)

entered into 45 challenges

contributed 0 challenges