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

Paste a column after a column - 2504 entries

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

  • Best score: 14
  • Best player score: 190
  • Position: #545 / 547
  • Number of attempts: 1
2 quick changes and a numbered list - 642 entries

The ascii will not be lost, but rather numbered in 4 digit blocks with leading zeros.

  • Best score: 37
  • Best player score: 96
  • Position: #137 / 153
  • Number of attempts: 1
delete swap - 1768 entries

delete all swap

  • Best score: 5
  • Best player score: 8
  • Position: #420 / 548
  • Number of attempts: 2
Fix the shell script! - 2544 entries

Fix the shell script with the fewest keystrokes!

  • Best score: 26
  • Best player score: 63
  • Position: #530 / 589
  • Number of attempts: 1
Visual block training - 1069 entries

You see the input. You see the output. Go.

  • Best score: 17
  • Best player score: 59
  • Position: #163 / 203
  • Number of attempts: 1
Put a newline after every 10 lines in vim - 1656 entries

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

  • Best score: 10
  • Best player score: 32
  • Position: #532 / 555
  • Number of attempts: 1
hello-world-vimgolf - 2490 entries

Simple number generation

  • Best score: 10
  • Best player score: 19
  • Position: #618 / 705
  • Number of attempts: 1
Increment number for every 10 lines - 229 entries

The file consists of 2 columns (code and percentage). We need to add 2 more columns with increasing number for 4th column (Xcols) and increment 3rd column (Ycols) only for every 10 lines with reset of 4th column

  • Best score: 25
  • Best player score: 59
  • Position: #43 / 63
  • Number of attempts: 1
Making 3 line function a one liner. - 325 entries

Simple challenge for frequent action while programming.

  • Best score: 4
  • Best player score: 6
  • Position: #190 / 202
  • Number of attempts: 2
Modernise code - 1388 entries

Modernise and clean up some C++ code.

  • Best score: 34
  • Best player score: 47
  • Position: #206 / 319
  • Number of attempts: 1
Enumerate Bullets - 320 entries

We will need to refer to the bullet points in our document explicitly later, so we need to assign them some ID's!

  • Best score: 20
  • Best player score: 49
  • Position: #66 / 84
  • Number of attempts: 1
HS Final exam vimgolf - 897 entries

Change the initial file to a single line containing all names comma-separated with numbers inside parentheses.

  • Best score: 21
  • Best player score: 47
  • Position: #214 / 236
  • Number of attempts: 1
Easy modification of ssh config - 360 entries

Just add another alias to each worker

  • Best score: 24
  • Best player score: 61
  • Position: #98 / 111
  • Number of attempts: 1
Hogwarts Email Sorting - 915 entries

Given a list of emails, get the students full name and their associated house.

  • Best score: 20
  • Best player score: 29
  • Position: #220 / 259
  • Number of attempts: 1
Applying same text modification in several lines - 2865 entries

Remove identical text at the beginning of several lines and the closing parenthesis.

  • Best score: 12
  • Best player score: 12
  • Position: #21 / 846
  • Number of attempts: 6
Bad Copy Syntax - 2028 entries

Copy should be from right to left, but sometimes you type it wrong.

  • Best score: 18
  • Best player score: 29
  • Position: #424 / 522
  • Number of attempts: 1
Box it - 7902 entries

Create a box around a line.

  • Best score: 21
  • Best player score: 35
  • Position: #1631 / 1874
  • Number of attempts: 1
multiple cursor alternative - 1519 entries

from: https://www.reddit.com/r/vim/comments/6w5pfa/crosspost_from_remacs_how_would_you_do_this_in_vim/

  • Best score: 19
  • Best player score: 44
  • Position: #364 / 380
  • Number of attempts: 1
Every other line - 2910 entries

AaAaAaA

  • Best score: 12
  • Best player score: 14
  • Position: #297 / 703
  • Number of attempts: 6
Team names - 1834 entries

The team names are misspelled.

  • Best score: 16
  • Best player score: 22
  • Position: #535 / 587
  • Number of attempts: 1
Interweave two blocks of text - 658 entries

Suppose you've got data on a list of things from multiple sources. They're all in separate chunks, so how might you create a tabular output?

  • Best score: 15
  • Best player score: 30
  • Position: #210 / 213
  • Number of attempts: 1
Remember VimGolf Rules ! - 261 entries

Rules, ... and don't forget !

  • Best score: 7
  • Best player score: 8
  • Position: #125 / 141
  • Number of attempts: 2
Basic renumbering - 5645 entries

Renumbering Basic.

  • Best score: 11
  • Best player score: 22
  • Position: #969 / 1263
  • Number of attempts: 1
Generate a list of numbers - 295 entries

Please generate list of numbers from 1 to 20.

  • Best score: 14
  • Best player score: 17
  • Position: #130 / 140
  • Number of attempts: 2
convert yml into java pojo field - 857 entries

How fast vim can create fields for java pojo i.e class declaration referring to a (simple) yml file

  • Best score: 29
  • Best player score: 38
  • Position: #205 / 227
  • Number of attempts: 1
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: 43
  • Position: #446 / 446
  • Number of attempts: 1
replacing each line of a block selection - 2996 entries

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

  • Best score: 18
  • Best player score: 26
  • Position: #559 / 775
  • Number of attempts: 1
Reverse and double space - 499 entries

Reverse the order of the given lines and double space everything

  • Best score: 14
  • Best player score: 17
  • Position: #156 / 198
  • Number of attempts: 2
switch variable - 5065 entries

how fast can you switch two variable ?

  • Best score: 11
  • Best player score: 19
  • Position: #1661 / 1745
  • Number of attempts: 1
The meaning - 574 entries

Numbers are fun!

  • Best score: 5
  • Best player score: 5
  • Position: #309 / 362
  • Number of attempts: 5
Ugly spreadsheet copy/paste to CSV - 1007 entries

convert an ugly spreadsheet copy/paste into a CSV format.

  • Best score: 19
  • Best player score: 58
  • Position: #175 / 192
  • Number of attempts: 1
Replacing some words - 425 entries

How fast could it be?

  • Best score: 17
  • Best player score: 55
  • Position: #150 / 150
  • Number of attempts: 1
Make it more readable - 1986 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 25
  • Position: #622 / 646
  • Number of attempts: 2
Numbering a List - 1931 entries

Pretty simple, number the list.

  • Best score: 13
  • Best player score: 13
  • Position: #78 / 652
  • Number of attempts: 1
Ruby 1.9 hashes - 1236 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: 12
  • Best player score: 28
  • Position: #401 / 404
  • Number of attempts: 1
Reverse and count - 470 entries

Someone typed things upside down and now a Vim ninja needs to reverse the lines and count how many there are.

  • Best score: 18
  • Best player score: 20
  • Position: #21 / 175
  • Number of attempts: 1
Reverse Simple Deletion - 845 entries

You did the simple deletion, now reverse it.

  • Best score: 11
  • Best player score: 15
  • Position: #424 / 457
  • Number of attempts: 1
Thomas Hiron
Twitter:

Release Manager | WIDE Consultant - Annecy

entered into 37 challenges

contributed 0 challenges