Played Challenges
Find the devices that have no revoked time, and extract out the duration left on their leases. - 255 entries
Extract non-revoked devices and the duration of their leases.
- Best score: 49
- Best player score: 63
- Position: #24 / 60
- Number of attempts: 1
Convert list of enums to list of localization terms - 262 entries
While making my game Piloteer, I had a large list of TaskTypes and needed to convert them to an equivalent list of localization terms, to be used when translating the game's text into different languages.
- Best score: 75
- Best player score: 99
- Position: #19 / 74
- Number of attempts: 5
From brakets to parens - 1356 entries
This is one of the most common problem when you wrap an array for error handling. Vim is useful when you convert foo[i][j][k] into foo(i, j, k) for many times.
- Best score: 24
- Best player score: 40
- Position: #195 / 309
- Number of attempts: 1
Create json from a .env file - 1773 entries
A simple everyday task.
- Best score: 38
- Best player score: 48
- Position: #123 / 431
- Number of attempts: 3
Sort and Tag - 738 entries
The goal is to sort these lines alphabetically, assign a unique identifier to each line in the format "[01]", "[02]", etc., and then restore the original order of the lines while preserving the assigned identifiers.
- Best score: 36
- Best player score: 71
- Position: #60 / 157
- Number of attempts: 4
Changing date formats - 774 entries
Change the date format to Y/M/D.
- Best score: 36
- Best player score: 91
- Position: #131 / 213
- Number of attempts: 4
YAML to dotenv - 1654 entries
Convert this YAML config file to a .env file.
- Best score: 16
- Best player score: 22
- Position: #148 / 347
- Number of attempts: 2
Swap columns and transform to CSV format - 516 entries
Turn this spreadsheet output into a CSV file but first swap the columns
- Best score: 16
- Best player score: 17
- Position: #71 / 184
- Number of attempts: 4
Generate an entry for each month - 398 entries
The input file contains a URI with a month in it. Generate the URIs for all the other months up to a couple of years
- Best score: 27
- Best player score: 31
- Position: #5 / 102
- Number of attempts: 4
Fix the git merge conflicts - 394 entries
Solve the merge conflicts in the Python file
- Best score: 36
- Best player score: 53
- Position: #40 / 111
- Number of attempts: 2
CaN yOuR ViM dO ThAt? #1 - 309 entries
Tsoding's famous "Can your Vim do that?" https://youtu.be/Bafo3hhheHU?si=DfcT4sUEMTSAevnx&t=1091
- Best score: 41
- Best player score: 41
- Position: #24 / 123
- Number of attempts: 3
Fix timezone format - 385 entries
Add the missing T and Z in the datetime field. There should be a T instead of the space, and a Z at the end of the datetime. `2024-08-31 18:32:00;` -> `2024-08-31T18:32:00Z;`
- Best score: 15
- Best player score: 16
- Position: #38 / 126
- Number of attempts: 3
Rearrange array to single level - 1832 entries
The goal is to flatten the array into a single list and remove any empty elements.
- Best score: 14
- Best player score: 14
- Position: #20 / 308
- Number of attempts: 11
Rearrange array to one line - 907 entries
Rearrange the array content on only one line, and remove trailing commas
- Best score: 13
- Best player score: 13
- Position: #30 / 209
- Number of attempts: 10
Count words - 140 entries
Merge duplicates and count each word.
- Best score: 39
- Best player score: 42
- Position: #9 / 29
- Number of attempts: 9
Format a long line - 134 entries
Reformat long lines (gq), textwidth=78, no trailing spaces.
- Best score: 17
- Best player score: 24
- Position: #19 / 37
- Number of attempts: 6
Find anomalies - 187 entries
There is one special character per line
- Best score: 30
- Best player score: 70
- Position: #38 / 48
- Number of attempts: 2
Pick and sort servers from mirror list - 466 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: 29
- Position: #26 / 92
- Number of attempts: 7
Remove line numbers - 791 entries
From http://web.archive.org/web/20140831121704/http://dirac.org/linux/gdb/02a-Memory_Layout_And_The_Stack.php#investigatingthestackwithgdb.
- Best score: 8
- Best player score: 12
- Position: #85 / 210
- Number of attempts: 5
Surround the 'z' character with brackets, quotes, and print as formatted string. - 584 entries
Surround the 'z' character with brackets, quotes, and print as formatted string.
- Best score: 17
- Best player score: 17
- Position: #247 / 330
- Number of attempts: 1
Paste a column after a column - 2672 entries
This task is very common while using multi-cursor. What is the elegant vim way ?
- Best score: 7
- Best player score: 14
- Position: #117 / 580
- Number of attempts: 8
Reformat symbols in list - 1661 entries
Saw this in some lecture, easy reformatting using multiple cursor in VS Code
- Best score: 24
- Best player score: 27
- Position: #173 / 358
- Number of attempts: 2
delete swap - 1918 entries
delete all swap
- Best score: 5
- Best player score: 5
- Position: #393 / 583
- Number of attempts: 5
Fix the shell script! - 2710 entries
Fix the shell script with the fewest keystrokes!
- Best score: 26
- Best player score: 31
- Position: #291 / 637
- Number of attempts: 1
Put a newline after every 10 lines in vim - 1688 entries
Goal is to put a newline after every 10 lines in vim.
- Best score: 10
- Best player score: 12
- Position: #251 / 567
- Number of attempts: 3
Wikitext headings to markdown - 1039 entries
Convert the wikitext headings to markdown.
- Best score: 20
- Best player score: 20
- Position: #54 / 215
- Number of attempts: 3
hello-world-vimgolf - 2535 entries
Simple number generation
- Best score: 6
- Best player score: 10
- Position: #351 / 728
- Number of attempts: 3
Simple, Practical, and Common - 34031 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: #2428 / 7520
- Number of attempts: 7
Swap values - 4704 entries
Well, swap the values...
- Best score: 6
- Best player score: 12
- Position: #535 / 1294
- Number of attempts: 4
Wget failed to download redirections - 250 entries
Output of a wget session, where 302 where not properly handled due to certificate problems, has been saved to a file. Keep the correct URLs to start again downloading.
- Best score: 15
- Best player score: 15
- Position: #14 / 73
- Number of attempts: 7
Com(m)a Trouble - 3992 entries
Someone was real stupid when placing his commas. Can you fix it?
- Best score: 7
- Best player score: 12
- Position: #188 / 910
- Number of attempts: 1
Wrap the text of an email message to 79 characters - 885 entries
You're replying to an email with silly long lines. Clean them up.
- Best score: 5
- Best player score: 5
- Position: #343 / 458
- Number of attempts: 1
Search and Replace 0 - 5170 entries
Replace every instance of 'aaa' with 'xaaax'.
- Best score: 7
- Best player score: 12
- Position: #758 / 1680
- Number of attempts: 2
Just the middle - 11636 entries
Delete the instructions at the top and bottom.
- Best score: 7
- Best player score: 8
- Position: #3246 / 4262
- Number of attempts: 1
Python Hello World! Reformatting - 1057 entries
A novice Python using prints Hello World! and a pro shows him different way. Using vim to get into pro style from novice, win the challenge.
- Best score: 39
- Best player score: 44
- Position: #271 / 402
- Number of attempts: 1
Free hyphen! - 199 entries
Just like "Inner hyphens", but I'm giving you a free hyphen to play with. Will your solution be any different?
- Best score: 9
- Best player score: 9
- Position: #38 / 97
- Number of attempts: 2
comments galore - 1101 entries
Basic comment reformatting
- Best score: 10
- Best player score: 10
- Position: #312 / 433
- Number of attempts: 1
Separating firstname & lastname - 183 entries
Seperate named with equal tabs.
- Best score: 19
- Best player score: 20
- Position: #16 / 63
- Number of attempts: 6
Mute the second method of this script - 466 entries
prepend a # infront of every line of the second method
- Best score: 8
- Best player score: 9
- Position: #151 / 247
- Number of attempts: 1
I forgot quotes - 16255 entries
Oops.
- Best score: 10
- Best player score: 14
- Position: #2072 / 4229
- Number of attempts: 2
Execute immediate SQL - 107 entries
Sql string tranformation ...
- Best score: 58
- Best player score: 75
- Position: #24 / 34
- Number of attempts: 2
Changing URL path in CSS - 157 entries
What's the quickest way to swap out all the URLs in a CSS file? Is it wasted keystrokes using look-behinds and look-aheads? (I'm sorry for the delete/report--I made a mistake with the last one requiring an ugly search for graphic to replace with images. I just intended this to be a simple search and replace that might possibly generate some macros or normals solutions that are quicker)
- Best score: 40
- Best player score: 56
- Position: #55 / 66
- Number of attempts: 1
Cleanining up 80 column concatenated text - 229 entries
1. Put the whole query on one line, remove the concatenation operators 2. Remove the double spaces that appear a few times in the query 3. Use string-interpolated variable statementPid rather than the ugly concatenation
- Best score: 31
- Best player score: 48
- Position: #63 / 82
- Number of attempts: 1
Convert pandoc unordered list to a numbered list - 215 entries
I know it's possible to use #. in pandoc to auto-generate numbered lists, but then it's not easy to tell how many items there are when reading it in Markdown. How fast can you make the switch?
- Best score: 20
- Best player score: 22
- Position: #15 / 62
- Number of attempts: 2
Vertical Limit - 2642 entries
transform a succession of one word lines to a an array of strings
- Best score: 10
- Best player score: 26
- Position: #523 / 781
- Number of attempts: 1
Aligning function arguments to match a specific coding style - 279 entries
Most projects have specific coding style guidelines. In this case, the argument list must be broken into a new line for each argument, with the argument names right aligned, taking into account pointers.
- Best score: 16
- Best player score: 18
- Position: #42 / 75
- Number of attempts: 6
replacing each line of a block selection - 3070 entries
replace each line's ../assets/js with /javascripts
- Best score: 7
- Best player score: 19
- Position: #238 / 791
- Number of attempts: 5
Remove noise from HTTP log - 760 entries
This piece of log (from the year 2000) contains some irrelevant data. We only want to see the HTTP method and resource.
- Best score: 15
- Best player score: 16
- Position: #205 / 282
- Number of attempts: 1
Remove semicolons after expressions - 690 entries
A follow-up for http://vimgolf.com/challenges/4fc9d767d3a0d4000100000e.
- Best score: 6
- Best player score: 6
- Position: #140 / 272
- Number of attempts: 6
switch variable - 5136 entries
how fast can you switch two variable ?
- Best score: 9
- Best player score: 12
- Position: #1021 / 1767
- Number of attempts: 1
Ugly spreadsheet copy/paste to CSV - 1046 entries
convert an ugly spreadsheet copy/paste into a CSV format.
- Best score: 19
- Best player score: 26
- Position: #82 / 199
- Number of attempts: 4
Make it more readable - 2041 entries
Insert blank lines to make it more organized and readable
- Best score: 13
- Best player score: 14
- Position: #209 / 659
- Number of attempts: 2
PHP Array Syntax -> MailChimp Merge Syntax - 569 entries
I recently needed to send an e-mail to our marketing department listing allowed merge tags for our MailChimp campaigns. The allowed merge tags were determined from a PHP array in one of our PHP classes. I transformed the PHP class to MailChimp's syntax and sent the e-mail. It was, however, a long, laborious process. I'm still fairly new to Vim and would love to see how an expert Vim user would tackle one of my own, real-world problems. Thanks and have fun!
- Best score: 23
- Best player score: 24
- Position: #49 / 152
- Number of attempts: 5
Case preserving word replacement - 477 entries
Half way through my project, my people turned into dogs. Now I have to change everything in my source.
- Best score: 19
- Best player score: 20
- Position: #86 / 186
- Number of attempts: 7
imports alignment (python) - 729 entries
Align as one import per line.
- Best score: 17
- Best player score: 29
- Position: #154 / 205
- Number of attempts: 1
HTML to Haml - 906 entries
Help convert this HTML page to Haml.
- Best score: 23
- Best player score: 32
- Position: #81 / 208
- Number of attempts: 2
Numbering a List - 1970 entries
Pretty simple, number the list.
- Best score: 13
- Best player score: 13
- Position: #91 / 662
- Number of attempts: 1
The holy-grail may help - 408 entries
Can you find it in less than 20 strokes, Arthur?
- Best score: 16
- Best player score: 16
- Position: #168 / 222
- Number of attempts: 2
Assignment Alignment - 909 entries
line up the operators. Use spaces, not tabs.
- Best score: 18
- Best player score: 19
- Position: #78 / 226
- Number of attempts: 9
Sorting paragraphs - 570 entries
Order the paragraphs correctly, per prefixed index
- Best score: 18
- Best player score: 25
- Position: #62 / 171
- Number of attempts: 4
Context insensitive completion 0 - 611 entries
Buried in the lines you're not supposed to add is the line "Add this line!" Add that line to the top of the file.
- Best score: 6
- Best player score: 7
- Position: #136 / 258
- Number of attempts: 2
Reformat some Python - 660 entries
Fix some very bizarrely laid-out code.
- Best score: 34
- Best player score: 42
- Position: #129 / 249
- Number of attempts: 3
Reformat a C golf submission - 682 entries
Take this C golf submission (for the "tiny but standards-compliant Hello World program" category, naturally), and turn it into formatted C code.
- Best score: 22
- Best player score: 28
- Position: #78 / 223
- Number of attempts: 2
Reformat most common surnames - 848 entries
Reformat copy-pasted table into a list of the most common surnames
- Best score: 23
- Best player score: 27
- Position: #104 / 242
- Number of attempts: 5
Get rid of html tags - 466 entries
Want to read more about Vim's background? Then get rid of those html tags...
- Best score: 12
- Best player score: 16
- Position: #33 / 263
- Number of attempts: 2
Change the content of a string - 1810 entries
This docstring is a complete lie. Fix it.
- Best score: 22
- Best player score: 22
- Position: #260 / 659
- Number of attempts: 3
Sort and add attributes - 1605 entries
Sort the states and add the attribute country to each record.
- Best score: 33
- Best player score: 35
- Position: #457 / 622
- Number of attempts: 2
Reconstruct the Sentence - 1763 entries
Get the sentence back in the proper order, remove duplicate lines, and then combine the separate lines into one.
- Best score: 19
- Best player score: 21
- Position: #279 / 461
- Number of attempts: 3
Flodder-challenge - 1527 entries
Replace the text the most efficient and win!
- Best score: 27
- Best player score: 36
- Position: #211 / 384
- Number of attempts: 1
Simple text editing with Vim - 13682 entries
Make the pairs of lines match up by making each second line same as first
- Best score: 13
- Best player score: 16
- Position: #2443 / 3920
- Number of attempts: 3
Reformat/Refactor a Golfer Class - 7737 entries
A simple case of removing unneeded code and fixing broken indentation.
- Best score: 7
- Best player score: 41
- Position: #1008 / 1901
- Number of attempts: 4
VimGolf