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 - 852 entries

You're replying to an email with silly long lines. Clean them up.

  • Best score: 5
  • Best player score: 5
  • Position: #154 / 441
  • Number of attempts: 2
A HAPPY NEW YEAR 2014 ! - 10721 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 11
  • Position: #45 / 3704
  • Number of attempts: 4
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: 10
  • Position: #81 / 520
  • Number of attempts: 3
quotes inside quotes - 3185 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 / 1086
  • Number of attempts: 3
Prefixes and suffixes - 649 entries

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

  • Best score: 17
  • Best player score: 30
  • Position: #152 / 205
  • Number of attempts: 2
abcd > a b c d - 299 entries

transform the single spaces into 4 spaces repeat for each line

  • Best score: 15
  • Best player score: 15
  • Position: #59 / 228
  • Number of attempts: 1
Readable Rubyhash - 274 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: #52 / 97
  • 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 - 2015 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 15
  • Position: #251 / 654
  • Number of attempts: 3
remove dupes from array - 1361 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 / 338
  • Number of attempts: 5
HTML to Haml - 883 entries

Help convert this HTML page to Haml.

  • Best score: 23
  • Best player score: 48
  • Position: #163 / 206
  • 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 - 897 entries

line up the operators. Use spaces, not tabs.

  • Best score: 18
  • Best player score: 30
  • Position: #170 / 223
  • Number of attempts: 2
Shebangs for all - 2062 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: #323 / 525
  • Number of attempts: 3
The Cake is a Lie - 1389 entries

Correct the capitalization of each word

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

Finish writing this simple Python HTTP server.

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

Fix some very bizarrely laid-out code.

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

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

  • Best score: 16
  • Best player score: 17
  • Position: #88 / 841
  • Number of attempts: 12
Simple text editing with Vim - 13427 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 / 3849
  • Number of attempts: 9
Reformat/Refactor a Golfer Class - 7517 entries

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

  • Best score: 7
  • Best player score: 38
  • Position: #657 / 1851
  • 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