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

Generate a very basic Python constructor (fixed) - 1172 entries

Original by @BiddulphCaleb (http://www.vimgolf.com/challenges/6019f1c4642668000cee11e8) - had some extra spaces in output file.

  • Best score: 29
  • Best player score: 41
  • Position: #105 / 245
  • Number of attempts: 5
hello-world-vimgolf - 2346 entries

Simple number generation

  • Best score: 10
  • Best player score: 10
  • Position: #202 / 663
  • Number of attempts: 1
Contribute to keyboard mashing - 839 entries

Speak in tongues

  • Best score: 17
  • Best player score: 18
  • Position: #93 / 256
  • Number of attempts: 2
Reordering Lorem Ipsum - 261 entries

Who even sorted this?

  • Best score: 13
  • Best player score: 14
  • Position: #32 / 61
  • Number of attempts: 1
Fill in the chess board - 905 entries

Fill in the name of each square using its file (a-h) and rank (1-8).

  • Best score: 19
  • Best player score: 36
  • Position: #91 / 175
  • Number of attempts: 1
Create a diamond comment - 305 entries

Encapsulate the text in a diamond pattern.

  • Best score: 27
  • Best player score: 38
  • Position: #39 / 71
  • Number of attempts: 1
Simple, Practical, and Common - 33379 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: 26
  • Position: #3404 / 7363
  • Number of attempts: 2
Swap values inside brackets - 2464 entries

Easy challenge.

  • Best score: 14
  • Best player score: 18
  • Position: #321 / 569
  • Number of attempts: 1
V to the i - 4751 entries

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

  • Best score: 7
  • Best player score: 8
  • Position: #927 / 1879
  • Number of attempts: 1
Com(m)a Trouble - 3660 entries

Someone was real stupid when placing his commas. Can you fix it?

  • Best score: 12
  • Best player score: 15
  • Position: #393 / 824
  • Number of attempts: 3
Extract argument from function - 2314 entries

The aim is to see if you can do some refactoring very fast.

  • Best score: 13
  • Best player score: 16
  • Position: #507 / 744
  • Number of attempts: 1
Number Sort - 303 entries

sort the list of newline-separated numbers incrementally. Numbers are in the range 1 to 1000, with 500 missing

  • Best score: 9
  • Best player score: 9
  • Position: #128 / 162
  • Number of attempts: 1
That hyphen - 2556 entries

"vim vi improved"

  • Best score: 9
  • Best player score: 11
  • Position: #374 / 695
  • Number of attempts: 3
Just the middle - 11358 entries

Delete the instructions at the top and bottom.

  • Best score: 7
  • Best player score: 8
  • Position: #2721 / 4163
  • Number of attempts: 3
Basic renumbering - 5587 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 28
  • Position: #1186 / 1258
  • Number of attempts: 1
Simple addition - 310 entries

The right side of the equation is already there. We just need the left one now.

  • Best score: 12
  • Best player score: 13
  • Position: #75 / 117
  • Number of attempts: 1
Vice versa - 7797 entries

Little role switching.

  • Best score: 12
  • Best player score: 17
  • Position: #1455 / 2099
  • Number of attempts: 2
Vim's not included features - 210 entries

Filter not included (-) features in a hypothetical installation of vim.

  • Best score: 23
  • Best player score: 34
  • Position: #44 / 62
  • Number of attempts: 1
Condensed Cases - 788 entries

Apple's new programming language, Swift, allows two style of case statements: 1) one Enum case on each line, or 2) multiple Enum cases on a single line. Convert the following from the first case (no pun intended) to the second type.

  • Best score: 12
  • Best player score: 19
  • Position: #210 / 242
  • Number of attempts: 1
Pretty format for variable declarations - 155 entries

Project standards demand the equal signs must be aligned for better readability.

  • Best score: 13
  • Best player score: 18
  • Position: #43 / 62
  • Number of attempts: 2
I forgot quotes - 15931 entries

Oops.

  • Best score: 10
  • Best player score: 15
  • Position: #2249 / 4161
  • Number of attempts: 2
Shift down - 193 entries

Number words are back.

  • Best score: 19
  • Best player score: 30
  • Position: #50 / 67
  • Number of attempts: 1
-a-b-c- - 3176 entries

Put hyphens everywhere.

  • Best score: 13
  • Best player score: 16
  • Position: #768 / 1129
  • Number of attempts: 1
Count both ways - 1001 entries

Right AND down.

  • Best score: 13
  • Best player score: 17
  • Position: #290 / 351
  • Number of attempts: 1
Gray area - 732 entries

It's a golf metaphor or something.

  • Best score: 11
  • Best player score: 14
  • Position: #203 / 268
  • Number of attempts: 1
Do you demand a shrubbery? - 1120 entries

Use :redir and crush the emacsgolfers.

  • Best score: 15
  • Best player score: 15
  • Position: #38 / 293
  • Number of attempts: 10
Don't know what this is - 1978 entries

Replace contents of brackets with matching number of spaces. Don't ask what the format's supposed to be.

  • Best score: 11
  • Best player score: 14
  • Position: #312 / 578
  • Number of attempts: 1
Where should I put the Newline? - 863 entries

Help me put the newline.

  • Best score: 7
  • Best player score: 7
  • Position: #124 / 431
  • Number of attempts: 2
A HAPPY NEW YEAR 2014 ! - 10624 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 11
  • Position: #1586 / 3666
  • Number of attempts: 4
attr_aligner - 3444 entries

Two attr keywords. Two separate indentations. Align the colons.

  • Best score: 19
  • Best player score: 35
  • Position: #577 / 692
  • Number of attempts: 1
Letter case trickery - 1594 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: #170 / 511
  • Number of attempts: 1
quotes inside quotes - 3125 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: 16
  • Position: #599 / 1072
  • Number of attempts: 2
Words in parens - 12854 entries

We should all ace this, right?

  • Best score: 13
  • Best player score: 16
  • Position: #2442 / 3945
  • Number of attempts: 3
switch variable - 5031 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 11
  • Position: #654 / 1735
  • Number of attempts: 1
It'ss tooo coold too typpe todaay - 215 entries

My hands are numb with cold. It's hard to type correctly.

  • Best score: 16
  • Best player score: 21
  • Position: #42 / 96
  • Number of attempts: 1
Simple text editing with Vim - 12276 entries

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

  • Best score: 13
  • Best player score: 14
  • Position: #1333 / 3578
  • Number of attempts: 2
Reformat/Refactor a Golfer Class - 6548 entries

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

  • Best score: 32
  • Best player score: 39
  • Position: #701 / 1612
  • Number of attempts: 1
Andy Tockman
Twitter:

i like math, programming, linguistics, music, puzzles, and games

entered into 37 challenges

contributed 0 challenges