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

Populate 3D bone names list - 525 entries

Ran into this at work, excited to see how this gets optimized

  • Best score: 21
  • Best player score: 28
  • Position: #69 / 141
  • Number of attempts: 4
Paste a column after a column - 2413 entries

This task is very common while using multi-cursor. What is the elegant vim way ?

  • Best score: 14
  • Best player score: 23
  • Position: #340 / 523
  • Number of attempts: 2
HS exam question - 1523 entries

Convert the data to a python dictionary

  • Best score: 47
  • Best player score: 61
  • Position: #127 / 404
  • Number of attempts: 2
Fizzbuzz - 539 entries

type the first 100 lines of the fizzbuzz problem

  • Best score: 45
  • Best player score: 73
  • Position: #71 / 162
  • Number of attempts: 2
delete swap - 1650 entries

delete all swap

  • Best score: 5
  • Best player score: 14
  • Position: #462 / 514
  • Number of attempts: 1
Put a newline after every 10 lines in vim - 1649 entries

Goal is to put a newline after every 10 lines in vim.

  • Best score: 10
  • Best player score: 13
  • Position: #395 / 551
  • Number of attempts: 2
hello-world-vimgolf - 2472 entries

Simple number generation

  • Best score: 10
  • Best player score: 10
  • Position: #299 / 699
  • Number of attempts: 4
Generate a very basic Python constructor - 315 entries

I actually needed to do this myself, so I look forward to learning how.

  • Best score: 38
  • Best player score: 60
  • Position: #65 / 97
  • Number of attempts: 4
Python dataclasses - 1121 entries

Simple challenge to extract fields from a Python class

  • Best score: 19
  • Best player score: 27
  • Position: #164 / 281
  • Number of attempts: 3
Multiline to Single Line - 680 entries

Convert a multiline, indented file to a single line with no whitespace

  • Best score: 5
  • Best player score: 16
  • Position: #294 / 298
  • Number of attempts: 1
Copy three lines - 2869 entries

If the site is up (by some miracle), make the text under every header identical.

  • Best score: 13
  • Best player score: 20
  • Position: #427 / 639
  • Number of attempts: 2
Start coding format - 149 entries

I used to start coding with following format: int main(){ -(cursor here) }

  • Best score: 22
  • Best player score: 27
  • Position: #69 / 71
  • Number of attempts: 3
Order and join - 965 entries

There's something special about the input order.

  • Best score: 10
  • Best player score: 13
  • Position: #190 / 258
  • Number of attempts: 5
Array of characters - 157 entries

We all copy paste things off the internet, but the syntax doesn't look right. Fix it as fast as possible.

  • Best score: 33
  • Best player score: 89
  • Position: #46 / 46
  • Number of attempts: 1
I forgot quotes - 15946 entries

Oops.

  • Best score: 10
  • Best player score: 17
  • Position: #3075 / 4166
  • Number of attempts: 1
A HAPPY NEW YEAR 2014 ! - 10652 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 15
  • Position: #3206 / 3677
  • Number of attempts: 1
Letter case trickery - 1598 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: 12
  • Position: #360 / 514
  • Number of attempts: 1
Python: Lots of function arguments - 105 entries

The function definition is too long for one line. The modeline helps you with some typical Python indent settings.

  • Best score: 6
  • Best player score: 24
  • Position: #42 / 48
  • Number of attempts: 3
Let's play some Ivmgolf - 1096 entries

Oops, I spelled that wrong.

  • Best score: 7
  • Best player score: 7
  • Position: #141 / 442
  • Number of attempts: 5
Vertical Limit - 2487 entries

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

  • Best score: 21
  • Best player score: 31
  • Position: #674 / 748
  • Number of attempts: 2
Make the circuit grid! - 91 entries

Copy this command for a circuit layout program to create 10 total smd commands. Increment the number in quotes to name each pad, and add 0.7 to each of the (X Y) coordinates at the end of each line.

  • Best score: 26
  • Best player score: 48
  • Position: #44 / 49
  • Number of attempts: 1
replacing each line of a block selection - 2966 entries

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

  • Best score: 18
  • Best player score: 25
  • Position: #546 / 772
  • Number of attempts: 5
The meaning - 566 entries

Numbers are fun!

  • Best score: 5
  • Best player score: 5
  • Position: #319 / 360
  • Number of attempts: 1
Reverse Simple Deletion - 834 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 12
  • Position: #372 / 455
  • Number of attempts: 1
小世界
Twitter:

entered into 24 challenges

contributed 0 challenges