Played Challenges
Simple, Practical, and Common - 34033 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: #254 / 7519
- Number of attempts: 4
V to the i - 4887 entries
Input is 99 V's. Output is 100 i's.
- Best score: 7
- Best player score: 7
- Position: #6 / 1916
- Number of attempts: 2
Wrap the text of an email message to 79 characters - 873 entries
You're replying to an email with silly long lines. Clean them up.
- Best score: 5
- Best player score: 5
- Position: #206 / 455
- Number of attempts: 1
Extract argument from function - 2429 entries
The aim is to see if you can do some refactoring very fast.
- Best score: 13
- Best player score: 13
- Position: #64 / 773
- Number of attempts: 4
Search and Replace 0 - 5167 entries
Replace every instance of 'aaa' with 'xaaax'.
- Best score: 12
- Best player score: 12
- Position: #336 / 1677
- Number of attempts: 3
That hyphen - 2649 entries
"vim vi improved"
- Best score: 9
- Best player score: 11
- Position: #290 / 712
- Number of attempts: 2
Just the middle - 11630 entries
Delete the instructions at the top and bottom.
- Best score: 7
- Best player score: 7
- Position: #89 / 4261
- Number of attempts: 3
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: 43
- Position: #181 / 402
- Number of attempts: 1
Acute accents - 43 entries
Featuring all 17 lowercase letters with an acute accent digraph. Find a way to automate the digraphs.
- Best score: 18
- Best player score: 18
- Position: #3 / 28
- Number of attempts: 2
Basic renumbering - 5737 entries
Renumbering Basic.
- Best score: 11
- Best player score: 15
- Position: #516 / 1281
- Number of attempts: 2
Change your calendar - 421 entries
Happy New Year!
- Best score: 18
- Best player score: 35
- Position: #56 / 89
- Number of attempts: 1
VimGolfNight - 604 entries
Based on "The name of the game".
- Best score: 12
- Best player score: 12
- Position: #183 / 357
- Number of attempts: 1
Condensed Cases - 829 entries
Apple's new programming language, Swift, allows two style of case statements: 1) one Enum case on each line, or 2) multiple Enum cases on a single line. Convert the following from the first case (no pun intended) to the second type.
- Best score: 12
- Best player score: 14
- Position: #113 / 255
- Number of attempts: 1
Square numbers - 142 entries
Boring math puzzle.
- Best score: 16
- Best player score: 25
- Position: #15 / 47
- Number of attempts: 1
Happy TvvO - 443 entries
Don’t forget the past, learn from it. Happy New Year.
- Best score: 12
- Best player score: 12
- Position: #46 / 213
- Number of attempts: 1
I forgot quotes - 16240 entries
Oops.
- Best score: 10
- Best player score: 10
- Position: #12 / 4226
- Number of attempts: 3
Shift down - 238 entries
Number words are back.
- Best score: 19
- Best player score: 19
- Position: #10 / 72
- Number of attempts: 4
learn vim in short time - 248 entries
so happy to learn vim.because vim is awesome
- Best score: 8
- Best player score: 8
- Position: #16 / 168
- Number of attempts: 1
vim1001 - 331 entries
change number 1001 into a "vim1001 sequence". (My first challenge, hope it is not too bad... )
- Best score: 17
- Best player score: 21
- Position: #20 / 113
- Number of attempts: 2
Subtraction - 204 entries
Solve the equations.
- Best score: 18
- Best player score: 18
- Position: #7 / 64
- Number of attempts: 3
Roman numerals - 107 entries
Use the substitutions on top to convert unary to Roman numerals.
- Best score: 17
- Best player score: 19
- Position: #13 / 33
- Number of attempts: 2
-a-b-c- - 3242 entries
Put hyphens everywhere.
- Best score: 13
- Best player score: 13
- Position: #16 / 1147
- Number of attempts: 2
Count both ways - 1053 entries
Right AND down.
- Best score: 13
- Best player score: 13
- Position: #4 / 362
- Number of attempts: 2
Suffix sort - 301 entries
Sort from the end of the line, as if the letters in each line were reversed.
- Best score: 19
- Best player score: 25
- Position: #40 / 69
- Number of attempts: 2
NBCU Weekly Challenge - Test - 265 entries
Just testing.
- Best score: 18
- Best player score: 18
- Position: #3 / 121
- Number of attempts: 2
Change name of a variable - 197 entries
Replace the name of the $variable with the fastest move possible. The challenge is having a command that allow you to easily change the variable name even if its indented.
- Best score: 9
- Best player score: 9
- Position: #8 / 148
- Number of attempts: 1
Lisp Condense - 485 entries
Reduce 4 cons selection operations down to one function call.
- Best score: 13
- Best player score: 13
- Position: #2 / 163
- Number of attempts: 3
120 Degrees - 518 entries
Rotate that triangle.
- Best score: 14
- Best player score: 18
- Position: #56 / 148
- Number of attempts: 3
Gray area - 765 entries
It's a golf metaphor or something.
- Best score: 11
- Best player score: 12
- Position: #34 / 277
- Number of attempts: 2
NBCU Weekly Challenge - #0 - 164 entries
One of our favorites lines here at NBCU! p.s. The first version of #0 was deleted due to me copy/pasting a HTML entity. Congrats to the one who figured that out, you are a true ninja warrior!
- Best score: 28
- Best player score: 30
- Position: #7 / 62
- Number of attempts: 3
Refactor static member invocation - 235 entries
Someone used a static method. Refactor the method into a static import while fixing the assertion.
- Best score: 28
- Best player score: 29
- Position: #15 / 68
- Number of attempts: 2
Winding path - 143 entries
It's a maze, but the bad paths have been blocked off. Mark the correct path.
- Best score: 27
- Best player score: 46
- Position: #20 / 43
- Number of attempts: 1
Comparing scores - 148 entries
If Alice and Bob both did the challenge, put their entries together in the top paragraph, so we can compare their scores more easily.
- Best score: 18
- Best player score: 31
- Position: #23 / 37
- Number of attempts: 5
Neither Fizz nor Buzz - 271 entries
Not your regular increment macro! The gaps are tricky.
- Best score: 13
- Best player score: 20
- Position: #37 / 107
- Number of attempts: 1
Do you demand a shrubbery? - 1208 entries
Use :redir and crush the emacsgolfers.
- Best score: 15
- Best player score: 15
- Position: #4 / 310
- Number of attempts: 5
Don't know what this is - 2070 entries
Replace contents of brackets with matching number of spaces. Don't ask what the format's supposed to be.
- Best score: 11
- Best player score: 12
- Position: #145 / 596
- Number of attempts: 3
Two become one - 739 entries
We have two c arrays and want to make one two dimensional out of it. Can we do that?
- Best score: 25
- Best player score: 32
- Position: #116 / 213
- Number of attempts: 1
Where should I put the Newline? - 912 entries
Help me put the newline.
- Best score: 7
- Best player score: 7
- Position: #56 / 451
- Number of attempts: 2
Split the words - 399 entries
Add the spaces manually if you must, but if you use Vim's spell checking feature wisely, I think you'll save a LARGE number of strokes.
- Best score: 18
- Best player score: 28
- Position: #31 / 115
- Number of attempts: 4
A HAPPY NEW YEAR 2014 ! - 10758 entries
A HAPPY NEW YEAR 2014 !
- Best score: 11
- Best player score: 11
- Position: #381 / 3717
- Number of attempts: 5
Letter case trickery - 1688 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: 11
- Position: #259 / 526
- Number of attempts: 2
quotes inside quotes - 3203 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: #169 / 1094
- Number of attempts: 5
Hanging Indent for Footnotes - 92 entries
Format this footnote (in kramdown syntax) so that it has hanging indent.
- Best score: 17
- Best player score: 29
- Position: #32 / 33
- Number of attempts: 2
Sort the VimGolf challenges by popularity - 370 entries
"Sort by popularity" is a good order to play the challenges. Not perfect, but you could do a lot worse. ;) Input is a sample copy-pasted from vimgolf.com. Some of the challenge names have digits that will get in your way, so read ":help :sort" for hints on sorting with a regex. When you're done, try your solution on the full list!
- Best score: 15
- Best player score: 16
- Position: #56 / 111
- Number of attempts: 2
Words in parens - 13058 entries
We should all ace this, right?
- Best score: 13
- Best player score: 14
- Position: #412 / 3993
- Number of attempts: 3
Pairs of numbers - 388 entries
Line 1 represents x, line 2 y-data. Bring the corresponding pairs in the form "[x,y]\n"
- Best score: 26
- Best player score: 29
- Position: #42 / 139
- Number of attempts: 3
paste indent correction - JS - 125 entries
You copy some javascript code from a website and paste it into vim, it does not look good!
- Best score: 16
- Best player score: 16
- Position: #30 / 63
- Number of attempts: 1
Word frequency alignment - 310 entries
You've got to align the second column, but the spacing is inconvenient and there are nasty tabs in the way. If you're a "real Vim ninja," this could be very quick indeed...
- Best score: 5
- Best player score: 5
- Position: #91 / 166
- Number of attempts: 1
Minimalist Limerick - 540 entries
Reproduce this lovely poem.
- Best score: 30
- Best player score: 37
- Position: #106 / 178
- Number of attempts: 2
fib.c cleanup - 80 entries
cleanup the file
- Best score: 15
- Best player score: 16
- Position: #40 / 59
- Number of attempts: 1
REDRUM - 203 entries
If you remember "The Shinning", the first time you saw the bloody word REDRUM you probably thinked "What the Hell is that?" Well, then you know that you need a little help from a looking-glass to make sense of it. Now it's time to use vim like a mirror to reveal the message.
- Best score: 14
- Best player score: 14
- Position: #16 / 71
- Number of attempts: 2
Groups magic - 175 entries
Regexp or macros for string converting: (a) -> ___ (abc) -> ____ (abcd) -> ______ All in the '(' replace to _ multiply by char count + ()
- Best score: 12
- Best player score: 14
- Position: #57 / 102
- Number of attempts: 2
Prefixes and suffixes - 669 entries
Generate all prefixes of "vimchallenge", then all suffixes.
- Best score: 17
- Best player score: 23
- Position: #63 / 208
- Number of attempts: 4
Checkerboard case pattern - 187 entries
All the squares are white. Make some of them black. But only the right ones.
- Best score: 15
- Best player score: 21
- Position: #43 / 64
- Number of attempts: 2
A simple change - 486 entries
Just change the numbers in the most efficient way ...
- Best score: 12
- Best player score: 12
- Position: #23 / 200
- Number of attempts: 3
SFD-ROC: The Quick Brown Fox - 212 entries
Someone has vandalized our text (again). Please fix to read: The Quick Brown Fox Jumps Over The Lazy Dog.
- Best score: 24
- Best player score: 28
- Position: #73 / 110
- Number of attempts: 1
The Quick Brown Fox Jumps Over The Lazy Vim - 464 entries
Someone has vandalized this text file and replaced the beginning character of one word in each line with a Big "X." Please remove the big X's, and fix each line to read "The Quick Brown Fox Jumps Over The Lazy Dog."
- Best score: 8
- Best player score: 11
- Position: #145 / 201
- Number of attempts: 1
lamb had a little Mary - 659 entries
"Mary" and "lamb" are swapped. Unswap them. Fast as you can.
- Best score: 16
- Best player score: 35
- Position: #93 / 179
- Number of attempts: 4
SFD-ROC: vimvimvim - 1643 entries
Oh no, this line is longer than 80 chars... put each 'vim' on a new line.
- Best score: 8
- Best player score: 8
- Position: #56 / 458
- Number of attempts: 4
Saving the hashes(#) - 2116 entries
The following file is copied from vimcasts.org(Its only for learning purpose,hope the site owner doesn't mind it), its probably the easiest of challenges.Our goal is to delete every line which doesn't contain a hash signs. The remaining hash signs with numbers are then sorted to get the final output.
- Best score: 20
- Best player score: 29
- Position: #339 / 488
- Number of attempts: 2
SFD-ROC: ROT13 Phonics - 120 entries
A is for apple, b is for ball, etc... This familiar phonics poem has been rotated 13 characters. Make the letter match the word.
- Best score: 6
- Best player score: 6
- Position: #44 / 80
- Number of attempts: 1
Let's play some Ivmgolf - 1166 entries
Oops, I spelled that wrong.
- Best score: 7
- Best player score: 7
- Position: #67 / 461
- Number of attempts: 3
you're stuck on jQuery < 1.7 - 401 entries
replace calls to jQuery 1.7+'s `on` with calls to pre 1.7 `bind`
- Best score: 25
- Best player score: 28
- Position: #52 / 116
- Number of attempts: 3
Enharmonic Equivalents - 74 entries
Transform # and b to digraphs
- Best score: 18
- Best player score: 22
- Position: #35 / 41
- Number of attempts: 2
Vertical Limit - 2641 entries
transform a succession of one word lines to a an array of strings
- Best score: 21
- Best player score: 23
- Position: #237 / 780
- Number of attempts: 5
Make the circuit grid! - 106 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: 26
- Position: #24 / 51
- Number of attempts: 3
Switch function arguments - 2237 entries
How to switch two arguments of a function.
- Best score: 11
- Best player score: 11
- Position: #100 / 687
- Number of attempts: 5
Append semicolon after expressions - 1088 entries
Some lines need the semicolon, some don't.
- Best score: 11
- Best player score: 11
- Position: #76 / 427
- Number of attempts: 3
Reverse and double space - 511 entries
Reverse the order of the given lines and double space everything
- Best score: 14
- Best player score: 16
- Position: #106 / 202
- Number of attempts: 3
Remove semicolons after expressions - 687 entries
A follow-up for http://vimgolf.com/challenges/4fc9d767d3a0d4000100000e.
- Best score: 6
- Best player score: 6
- Position: #75 / 271
- Number of attempts: 4
switch variable - 5131 entries
how fast can you switch two variable ?
- Best score: 11
- Best player score: 11
- Position: #309 / 1766
- Number of attempts: 4
The meaning - 589 entries
Numbers are fun!
- Best score: 5
- Best player score: 5
- Position: #231 / 369
- Number of attempts: 1
Make it more readable - 2041 entries
Insert blank lines to make it more organized and readable
- Best score: 13
- Best player score: 14
- Position: #171 / 659
- Number of attempts: 5
Complete the hex array data - 215 entries
Do not use external tools(e.g. tac, seq) [My interpretation of Rule #7]
- Best score: 23
- Best player score: 27
- Position: #45 / 76
- Number of attempts: 1
Complete the hex array data (Part II) - 192 entries
Do not use external tools(e.g. tac, seq) [My interpretation of Rule #7]
- Best score: 20
- Best player score: 26
- Position: #51 / 72
- Number of attempts: 2
It'ss tooo coold too typpe todaay - 238 entries
My hands are numb with cold. It's hard to type correctly.
- Best score: 16
- Best player score: 23
- Position: #66 / 101
- Number of attempts: 1
Generate English Alphabets - 540 entries
Start with a, get up to z.
- Best score: 19
- Best player score: 25
- Position: #138 / 216
- Number of attempts: 1
Insert a Markdown link - 474 entries
Put a link in a markdown document, using the after-the-paragraph format.
- Best score: 22
- Best player score: 24
- Position: #67 / 158
- Number of attempts: 4
Numbering a List - 1970 entries
Pretty simple, number the list.
- Best score: 13
- Best player score: 18
- Position: #143 / 662
- Number of attempts: 3
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: #134 / 222
- Number of attempts: 2
Ruby 1.9 hashes - 1314 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: 14
- Position: #240 / 420
- Number of attempts: 1
Assignment Alignment - 909 entries
line up the operators. Use spaces, not tabs.
- Best score: 18
- Best player score: 23
- Position: #109 / 226
- Number of attempts: 6
A Simple One - 1094 entries
Here is a very simple one - just to illustrate/introduce a vim feature that some people seem to miss...
- Best score: 9
- Best player score: 9
- Position: #389 / 682
- Number of attempts: 1
82 bottles of beer on the wall - 330 entries
Take them down. (sorry, only 82 bottles because the problem size is limited!)
- Best score: 106
- Best player score: 120
- Position: #42 / 150
- Number of attempts: 1
Reverse Simple Deletion - 875 entries
You did the simple deletion, now reverse it.
- Best score: 11
- Best player score: 12
- Position: #301 / 467
- Number of attempts: 1
Increment, increment, increment.... - 710 entries
Vim likes macros
- Best score: 10
- Best player score: 12
- Position: #295 / 418
- Number of attempts: 1
Hatsuyume - 583 entries
http://en.wikipedia.org/wiki/Hatsuyume
- Best score: 15
- Best player score: 25
- Position: #91 / 195
- Number of attempts: 2
The Cake is a Lie - 1419 entries
Correct the capitalization of each word
- Best score: 8
- Best player score: 9
- Position: #187 / 544
- Number of attempts: 3
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: 8
- Position: #155 / 258
- Number of attempts: 1
Compile C - 454 entries
You might have to get clever to do this one.
- Best score: 19
- Best player score: 21
- Position: #75 / 146
- Number of attempts: 4
Context Insensitive completion 1 - 535 entries
Finish writing this simple Python HTTP server.
- Best score: 18
- Best player score: 18
- Position: #118 / 253
- Number of attempts: 2
Almost encrypted - 212 entries
Convert the first paragraph to be even less readable.
- Best score: 5
- Best player score: 5
- Position: #109 / 150
- Number of attempts: 1
Make Fancy Header - 1111 entries
Make the header text stand out with surrounding asterisks
- Best score: 15
- Best player score: 17
- Position: #195 / 357
- Number of attempts: 2
Reverse characters in a line - 847 entries
You have everything you need, just not in the right order. Mastermind would give you 26 white pegs.
- Best score: 8
- Best player score: 18
- Position: #205 / 284
- Number of attempts: 4
Get rid of html tags - 465 entries
Want to read more about Vim's background? Then get rid of those html tags...
- Best score: 12
- Best player score: 17
- Position: #116 / 262
- Number of attempts: 1
Change the content of a string - 1807 entries
This docstring is a complete lie. Fix it.
- Best score: 22
- Best player score: 22
- Position: #139 / 658
- Number of attempts: 2
Sort and add attributes - 1601 entries
Sort the states and add the attribute country to each record.
- Best score: 33
- Best player score: 33
- Position: #183 / 619
- Number of attempts: 2
Simple text editing with Vim - 13667 entries
Make the pairs of lines match up by making each second line same as first
- Best score: 13
- Best player score: 14
- Position: #1357 / 3914
- Number of attempts: 2
Reformat/Refactor a Golfer Class - 7722 entries
A simple case of removing unneeded code and fixing broken indentation.
- Best score: 7
- Best player score: 36
- Position: #490 / 1896
- Number of attempts: 3
Contributed Challenges
Subtraction - 204 entries
Solve the equations.
VimGolf