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

Replace word while reserving first letter case - 370 entries

Window -> Door window -> door Windows -> Windows windows -> windows

  • Best score: 24
  • Best player score: 28
  • Position: #26 / 85
  • Number of attempts: 2
months to html list items - 551 entries

Turn the months into list items.

  • Best score: 22
  • Best player score: 27
  • Position: #91 / 154
  • Number of attempts: 2
Quicksort - 1558 entries

We need the numbers in the first row sorted as quickly as possible! Be careful not to disturb the data below the divider though: that must remain unchanged.

  • Best score: 6
  • Best player score: 7
  • Position: #126 / 343
  • Number of attempts: 7
EDN reformat - 1027 entries

The goal is to make the code more readable and concise while maintaining its functionality.

  • Best score: 17
  • Best player score: 24
  • Position: #93 / 145
  • Number of attempts: 5
Pick and sort servers from mirror list - 344 entries

Retrieve the primary server for each country from a mirror list file and organize them alphabetically by country name. Given a mirror list file containing server information for various countries, the objective is to extract the primary server from each country and then arrange these servers in alphabetical order based on the respective country names.

  • Best score: 28
  • Best player score: 32
  • Position: #32 / 75
  • Number of attempts: 3
Populate 3D bone names list - 450 entries

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

  • Best score: 21
  • Best player score: 28
  • Position: #63 / 119
  • Number of attempts: 3
Find fix point of cos - 1125 entries

Write a function to find the fix point of cos. It is not a good code; It is just to use vim. Inspired by the excellent https://mvanier.livejournal.com/2897.html about the Y combinator.

  • Best score: 14
  • Best player score: 15
  • Position: #191 / 337
  • Number of attempts: 2
Insert column data on Confluence-style table - 425 entries

Add ip addresses into new "IP" column based on the last digits from the "Server" column

  • Best score: 33
  • Best player score: 41
  • Position: #35 / 99
  • Number of attempts: 4
Surround the 'z' character with brackets, quotes, and print as formatted string. - 485 entries

Surround the 'z' character with brackets, quotes, and print as formatted string.

  • Best score: 17
  • Best player score: 17
  • Position: #186 / 271
  • Number of attempts: 1
Paste a column after a column - 2243 entries

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

  • Best score: 14
  • Best player score: 14
  • Position: #89 / 487
  • Number of attempts: 9
Filter number combinations that don't add to 11 - 376 entries

Append the sum of each line to its end, alongside an equals sign, and remove any that do not sum to 11. The ordering of lines should stay the same. Note that the combinations are semi-arbitrary and not all 4-number combinations are present in the file.

  • Best score: 27
  • Best player score: 27
  • Position: #39 / 110
  • Number of attempts: 5
Tabbed Table to Python Array - 643 entries

Not payed by the hour? So make it fast ;-) The table contains the relative occurencies of bigrams (two consecutive letters) in 1/100,000 in the german language, copy-pasted from http://www.mathe.tu-freiberg.de/~hebisch/cafe/kryptographie/bigramme.html

  • Best score: 50
  • Best player score: 60
  • Position: #80 / 166
  • Number of attempts: 2
HS exam question - 1503 entries

Convert the data to a python dictionary

  • Best score: 47
  • Best player score: 81
  • Position: #258 / 395
  • Number of attempts: 1
Reformat symbols in list - 1466 entries

Saw this in some lecture, easy reformatting using multiple cursor in VS Code

  • Best score: 24
  • Best player score: 27
  • Position: #156 / 322
  • Number of attempts: 3
Fizzbuzz - 509 entries

type the first 100 lines of the fizzbuzz problem

  • Best score: 47
  • Best player score: 105
  • Position: #134 / 157
  • Number of attempts: 1
Substraction (bis) - 578 entries

Solve the equations (adapted from the original @Caek_'s challenge).

  • Best score: 21
  • Best player score: 31
  • Position: #60 / 107
  • Number of attempts: 2
Changing around text with citations - 322 entries

Based off of something I saw on reddit

  • Best score: 28
  • Best player score: 41
  • Position: #58 / 88
  • Number of attempts: 2
Poorly indented Python comments - 1172 entries

Fix the alignment of some Python comments as quickly as possible.

  • Best score: 15
  • Best player score: 15
  • Position: #46 / 203
  • Number of attempts: 12
Many duplicates - 1253 entries

Quick and easy

  • Best score: 7
  • Best player score: 10
  • Position: #343 / 412
  • Number of attempts: 1
2 quick changes and a numbered list - 599 entries

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

  • Best score: 37
  • Best player score: 54
  • Position: #94 / 145
  • Number of attempts: 1
delete swap - 1522 entries

delete all swap

  • Best score: 5
  • Best player score: 5
  • Position: #316 / 476
  • Number of attempts: 1
Generate a very basic Python constructor (fixed) - 1175 entries

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

  • Best score: 29
  • Best player score: 40
  • Position: #102 / 246
  • Number of attempts: 3
Wikitext headings to markdown - 980 entries

Convert the wikitext headings to markdown.

  • Best score: 20
  • Best player score: 20
  • Position: #48 / 203
  • Number of attempts: 7
Plotting some variables in python - 1558 entries

4 sets of (x,y) variables to plot. Just increment the numbers! Well, let's change the colors of the lines as well. Oh and we meant to plot the absolute values of course.

  • Best score: 34
  • Best player score: 37
  • Position: #99 / 333
  • Number of attempts: 8
Simple, Practical, and Common - 33385 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: 27
  • Position: #4043 / 7364
  • Number of attempts: 1
Copy three lines - 2840 entries

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

  • Best score: 13
  • Best player score: 17
  • Position: #295 / 635
  • Number of attempts: 3
Add to end of each line... kinda - 325 entries

Visual-block mode can be used to add something to the end of each line, even if they are of differing lengths. However, what if it's not quite at the end?

  • Best score: 12
  • Best player score: 12
  • Position: #108 / 171
  • Number of attempts: 1
Vice versa - 7803 entries

Little role switching.

  • Best score: 12
  • Best player score: 13
  • Position: #849 / 2100
  • Number of attempts: 4
Maze path - 36 entries

Follow the given motions and mark your path with Xs. Attention: This maze is quite big (20x20), please set your terminal size to at least 82.

  • Best score: 25
  • Best player score: 47
  • Position: #9 / 15
  • Number of attempts: 1
Line under headers - 2004 entries

Put a line under each header, and remove the other markdown formatting.

  • Best score: 24
  • Best player score: 27
  • Position: #200 / 496
  • Number of attempts: 4
Assign numbers to fields - 105 entries

You are given a list of space-separated strings. Add an increasing numeric prefix to each one.

  • Best score: 19
  • Best player score: 19
  • Position: #26 / 59
  • Number of attempts: 3
A HAPPY NEW YEAR 2014 ! - 10624 entries

A HAPPY NEW YEAR 2014 !

  • Best score: 11
  • Best player score: 13
  • Position: #2601 / 3666
  • 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: 14
  • Position: #364 / 1072
  • Number of attempts: 3
Make it more readable - 1952 entries

Insert blank lines to make it more organized and readable

  • Best score: 13
  • Best player score: 14
  • Position: #200 / 640
  • Number of attempts: 5
Sort and add attributes - 1327 entries

Sort the states and add the attribute country to each record.

  • Best score: 33
  • Best player score: 33
  • Position: #272 / 529
  • Number of attempts: 2
Anaritus
Github:

entered into 35 challenges

contributed 0 challenges