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

Rural Post - 4563 entries

Simple challenge to remove all but the post code on each line

  • Best score: 9
  • Best player score: 9
  • Position: #10 / 1113
  • Number of attempts: 4
xrandr outputs and dashes - 724 entries

uh oh, different video drivers identify display outputs with more dashes. Quick, need to change this xrandr script!

  • Best score: 12
  • Best player score: 12
  • Position: #28 / 225
  • Number of attempts: 1
Yo To Hello - 1151 entries

Simply Turn Yo To Hello

  • Best score: 8
  • Best player score: 10
  • Position: #121 / 533
  • Number of attempts: 1
Simple, Practical, and Common - 33757 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: 22
  • Position: #2168 / 7450
  • Number of attempts: 7
prepend * to every non-blank line - 6358 entries

Prepend an asterisk to every non-blank line in the input file.

  • Best score: 10
  • Best player score: 10
  • Position: #201 / 1551
  • Number of attempts: 11
V to the i - 4824 entries

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

  • Best score: 7
  • Best player score: 9
  • Position: #1736 / 1899
  • Number of attempts: 1
Add semicolons - 10891 entries

Simply add a semicolon at the end of each line

  • Best score: 10
  • Best player score: 10
  • Position: #561 / 3077
  • Number of attempts: 3
Box it - 7954 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 23
  • Position: #758 / 1886
  • Number of attempts: 2
comment and uncomment code inline - 1151 entries

It's very useful to be able to comment out a block of code in a quick edit. And likewise to uncomment the code. This operation often involves multi-line stanzas and even large blocks. With just line-wise navigation and insert mode this would cost you about 4 keystrokes per line. Master this hole of VimGolf and you'll quickly drop your key count in day to day Vim as well.

  • Best score: 9
  • Best player score: 9
  • Position: #140 / 328
  • Number of attempts: 4
Delete to the end of the current line - 849 entries

Delete to the end of the current line, but keep the character under the cursor.

  • Best score: 5
  • Best player score: 5
  • Position: #232 / 407
  • Number of attempts: 2
I forgot quotes - 16051 entries

Oops.

  • Best score: 10
  • Best player score: 10
  • Position: #1038 / 4194
  • Number of attempts: 6
もりを
Twitter:

競プロ(morio__) / ぷよぷよ(@morio_puyo)

entered into 11 challenges

contributed 0 challenges