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

Search and Replace 0 - 5004 entries

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

  • Best score: 12
  • Best player score: 14
  • Position: #959 / 1630
  • Number of attempts: 1
VimGolfNight - 568 entries

Based on "The name of the game".

  • Best score: 12
  • Best player score: 12
  • Position: #63 / 349
  • Number of attempts: 1
Counting in binary - 526 entries

"a" represents 0; "A" represents 1. Start from zero and count to 15.

  • Best score: 16
  • Best player score: 41
  • Position: #80 / 117
  • Number of attempts: 2
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: 13
  • Position: #368 / 518
  • Number of attempts: 2
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: 18
  • Position: #956 / 1079
  • Number of attempts: 1
Number an outline - 280 entries

The indent and words are right, but the numbers are all wrong.

  • Best score: 25
  • Best player score: 48
  • Position: #37 / 78
  • Number of attempts: 2
Words in parens - 12967 entries

We should all ace this, right?

  • Best score: 13
  • Best player score: 16
  • Position: #1946 / 3969
  • Number of attempts: 2
Pairs of numbers - 363 entries

Line 1 represents x, line 2 y-data. Bring the corresponding pairs in the form "[x,y]\n"

  • Best score: 26
  • Best player score: 45
  • Position: #108 / 136
  • Number of attempts: 1
Assign list - 192 entries

Assign list elements to matrix

  • Best score: 30
  • Best player score: 55
  • Position: #48 / 61
  • Number of attempts: 1
Delete unwanted lines - 423 entries

Delete all lines which does not end in "o.."

  • Best score: 9
  • Best player score: 9
  • Position: #72 / 231
  • Number of attempts: 2
Minimalist Limerick - 520 entries

Reproduce this lovely poem.

  • Best score: 30
  • Best player score: 35
  • Position: #76 / 174
  • Number of attempts: 3
The name of the game - 671 entries

End up with the name of the game.

  • Best score: 11
  • Best player score: 11
  • Position: #130 / 362
  • Number of attempts: 1
lamb had a little Mary - 618 entries

"Mary" and "lamb" are swapped. Unswap them. Fast as you can.

  • Best score: 16
  • Best player score: 32
  • Position: #62 / 169
  • Number of attempts: 5
SFD-ROC: vimvimvim - 1606 entries

Oh no, this line is longer than 80 chars... put each 'vim' on a new line.

  • Best score: 8
  • Best player score: 9
  • Position: #190 / 446
  • Number of attempts: 6
Let's play some Ivmgolf - 1122 entries

Oops, I spelled that wrong.

  • Best score: 7
  • Best player score: 9
  • Position: #208 / 446
  • Number of attempts: 1
Vertical Limit - 2552 entries

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

  • Best score: 21
  • Best player score: 31
  • Position: #674 / 757
  • Number of attempts: 1
Exchanging Quotes - 858 entries

Sometimes you need to exchange a choice of quotes in some code.

  • Best score: 30
  • Best player score: 36
  • Position: #114 / 230
  • Number of attempts: 3
replacing each line of a block selection - 3001 entries

replace each line's ../assets/js with /javascripts

  • Best score: 18
  • Best player score: 21
  • Position: #361 / 778
  • Number of attempts: 3
Switch function arguments - 2142 entries

How to switch two arguments of a function.

  • Best score: 11
  • Best player score: 13
  • Position: #378 / 665
  • Number of attempts: 3
Remove noise from HTTP log - 717 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: 16
  • Position: #170 / 273
  • Number of attempts: 4
switch variable - 5079 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 14
  • Position: #1322 / 1749
  • Number of attempts: 1
Make it more readable - 2009 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 16
  • Position: #377 / 652
  • Number of attempts: 1
Numbering a List - 1935 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 21
  • Position: #389 / 654
  • Number of attempts: 1
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: 15
  • Position: #268 / 519
  • 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: 22
  • Position: #312 / 804
  • Number of attempts: 6
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: 14
  • Position: #1131 / 3739
  • Number of attempts: 4
Reformat/Refactor a Golfer Class - 7157 entries

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

  • Best score: 28
  • Best player score: 45
  • Position: #1158 / 1755
  • Number of attempts: 1
Andrew Crites
Twitter:

http://AySites.com is a cloud-based website storage engine. It mimics the famous Chrome new tab page and Opera speed dials with more fine grained customization

entered into 27 challenges

contributed 0 challenges