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

New teacher - 156 entries

Update the details of the new CS teacher.

  • Best score: 19
  • Best player score: 19
  • Position: #3 / 42
  • Number of attempts: 2
Truth Table to ModelSim - 27 entries

Convert this truth table to simulator instructions!

  • Best score: 64
  • Best player score: 64
  • Position: #1 / 11
  • Number of attempts: 2
Replace word while reserving first letter case - 372 entries

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

  • Best score: 24
  • Best player score: 24
  • Position: #1 / 86
  • Number of attempts: 2
months to html list items - 569 entries

Turn the months into list items.

  • Best score: 22
  • Best player score: 22
  • Position: #1 / 159
  • Number of attempts: 1
Instance creation in Verilog - 33 entries

Creating an instance of a module is a very frequent task in Verilog. Let's see how efficiently can it be done

  • Best score: 107
  • Best player score: 107
  • Position: #2 / 7
  • Number of attempts: 10
Quicksort - 1559 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: 6
  • Position: #3 / 344
  • Number of attempts: 1
EDN reformat - 1055 entries

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

  • Best score: 17
  • Best player score: 17
  • Position: #1 / 147
  • Number of attempts: 2
Tic-Tac-Toe Grid Transformation - 321 entries

Your mission is to efficiently convert the original Tic-Tac-Toe grid, represented by 'x's and 'o's, into a neat and well-organized game board.

  • Best score: 56
  • Best player score: 56
  • Position: #1 / 78
  • Number of attempts: 2
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: 28
  • Position: #1 / 75
  • Number of attempts: 5
Populate 3D bone names list - 456 entries

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

  • Best score: 21
  • Best player score: 21
  • Position: #2 / 120
  • Number of attempts: 2
Remove line numbers - 543 entries

From http://web.archive.org/web/20140831121704/http://dirac.org/linux/gdb/02a-Memory_Layout_And_The_Stack.php#investigatingthestackwithgdb.

  • Best score: 12
  • Best player score: 12
  • Position: #1 / 146
  • Number of attempts: 1
Find fix point of cos - 1137 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: 14
  • Position: #10 / 340
  • Number of attempts: 1
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: 33
  • Position: #4 / 99
  • Number of attempts: 2
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: #30 / 271
  • Number of attempts: 1
Easier Align - 347 entries

Align the columns of a markdown table

  • Best score: 51
  • Best player score: 51
  • Position: #1 / 90
  • Number of attempts: 7
Paste a column after a column - 2262 entries

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

  • Best score: 14
  • Best player score: 14
  • Position: #56 / 491
  • Number of attempts: 1
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: #19 / 110
  • Number of attempts: 1
Tabbed Table to Python Array - 644 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: 50
  • Position: #1 / 167
  • Number of attempts: 2
HS exam question - 1510 entries

Convert the data to a python dictionary

  • Best score: 47
  • Best player score: 47
  • Position: #1 / 397
  • Number of attempts: 2
Reformat symbols in list - 1470 entries

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

  • Best score: 24
  • Best player score: 24
  • Position: #4 / 323
  • Number of attempts: 1
Fizzbuzz - 510 entries

type the first 100 lines of the fizzbuzz problem

  • Best score: 45
  • Best player score: 47
  • Position: #5 / 157
  • Number of attempts: 2
Substraction (bis) - 578 entries

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

  • Best score: 21
  • Best player score: 21
  • Position: #3 / 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: 28
  • Position: #9 / 88
  • Number of attempts: 2
Many duplicates - 1253 entries

Quick and easy

  • Best score: 7
  • Best player score: 7
  • Position: #27 / 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: 37
  • Position: #12 / 145
  • Number of attempts: 1
delete swap - 1527 entries

delete all swap

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

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

  • Best score: 29
  • Best player score: 29
  • Position: #31 / 248
  • Number of attempts: 1
Fix the shell script! - 2344 entries

Fix the shell script with the fewest keystrokes!

  • Best score: 26
  • Best player score: 26
  • Position: #31 / 542
  • Number of attempts: 1
hello-world-vimgolf - 2361 entries

Simple number generation

  • Best score: 10
  • Best player score: 10
  • Position: #205 / 667
  • 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: 19
  • Position: #21 / 175
  • Number of attempts: 2
Generate a very basic Python constructor - 307 entries

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

  • Best score: 38
  • Best player score: 38
  • Position: #21 / 94
  • Number of attempts: 1
Making 3 line function a one liner. - 305 entries

Simple challenge for frequent action while programming.

  • Best score: 4
  • Best player score: 4
  • Position: #98 / 194
  • Number of attempts: 1
HS Final exam vimgolf - 864 entries

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

  • Best score: 21
  • Best player score: 21
  • Position: #26 / 227
  • Number of attempts: 2
Python: Def to Lambda - 423 entries

LAMBDA!!!

  • Best score: 19
  • Best player score: 19
  • Position: #72 / 149
  • Number of attempts: 1
Danilo J. S. Bellini 🥊🇧🇷
Twitter:

Music, Python, Linux/shell, DSP/Audio, Maths/Statistics, Science, LaTeX, Economics, Brazilian stocks, Games, Analytic Philosophy, Game theory, ...

entered into 34 challenges

contributed 0 challenges