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

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: 5
  • Position: #154 / 421
  • Number of attempts: 2
A HAPPY NEW YEAR 2014 ! - 10682 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 11
  • Position: #45 / 3689
  • Number of attempts: 4
Letter case trickery - 1630 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: 10
  • Position: #81 / 518
  • Number of attempts: 3
quotes inside quotes - 3165 entries

taken from tip 85 of the very good book 'Practical Vim: Edit Text at the Speed of Thought' ! I'd be interested what people use :)

  • Best score: 14
  • Best player score: 14
  • Position: #91 / 1079
  • Number of attempts: 3
Prefixes and suffixes - 635 entries

Generate all prefixes of "vimchallenge", then all suffixes.

  • Best score: 17
  • Best player score: 30
  • Position: #148 / 201
  • Number of attempts: 2
abcd > a b c d - 297 entries

transform the single spaces into 4 spaces repeat for each line

  • Best score: 15
  • Best player score: 15
  • Position: #59 / 226
  • Number of attempts: 1
Readable Rubyhash - 267 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: 23
  • Best player score: 28
  • Position: #51 / 95
  • Number of attempts: 3
Checkerboard case pattern - 164 entries

All the squares are white. Make some of them black. But only the right ones.

  • Best score: 15
  • Best player score: 17
  • Position: #27 / 61
  • Number of attempts: 4
Make it more readable - 2009 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 15
  • Position: #249 / 652
  • Number of attempts: 3
remove dupes from array - 1358 entries

given a random string that contains a ruby-esque array, make sure that there are no duplicate elements

  • Best score: 17
  • Best player score: 19
  • Position: #112 / 336
  • Number of attempts: 5
HTML to Haml - 881 entries

Help convert this HTML page to Haml.

  • Best score: 23
  • Best player score: 48
  • Position: #162 / 205
  • Number of attempts: 2
expand a list comprehension (python) - 334 entries

Please show your way to convert a list comprehension in python to an ordinary for-loop expression!

  • Best score: 42
  • Best player score: 60
  • Position: #81 / 110
  • Number of attempts: 1
Assignment Alignment - 885 entries

line up the operators. Use spaces, not tabs.

  • Best score: 18
  • Best player score: 30
  • Position: #168 / 221
  • Number of attempts: 2
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: 16
  • Position: #318 / 519
  • Number of attempts: 3
The Cake is a Lie - 1365 entries

Correct the capitalization of each word

  • Best score: 9
  • Best player score: 9
  • Position: #165 / 532
  • Number of attempts: 3
Context Insensitive completion 1 - 506 entries

Finish writing this simple Python HTTP server.

  • Best score: 18
  • Best player score: 18
  • Position: #111 / 247
  • Number of attempts: 2
Reformat some Python - 622 entries

Fix some very bizarrely laid-out code.

  • Best score: 34
  • Best player score: 34
  • Position: #29 / 238
  • Number of attempts: 3
Whitespace, empty lines and tabs - 3744 entries

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

  • Best score: 16
  • Best player score: 17
  • Position: #82 / 804
  • Number of attempts: 12
Simple text editing with Vim - 12996 entries

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

  • Best score: 13
  • Best player score: 13
  • Position: #231 / 3739
  • Number of attempts: 9
Reformat/Refactor a Golfer Class - 7157 entries

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

  • Best score: 28
  • Best player score: 38
  • Position: #633 / 1755
  • Number of attempts: 7
Daniel Jonsson
Twitter:

Studying software engineering at Chalmers University of Technology (2011-2016). #programming #python #linux #vim #firefox #OSS #FOSS #liberty

entered into 20 challenges

contributed 0 challenges