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 4d1a790fb8cb3409320001a8

Reformat most common surnames

Reformat copy-pasted table into a list of the most common surnames

Start file
Surname  	Approx Number  	% Frequency  	Rank  
SMITH	 2,501,922	1.006	1
JOHNSON	 2,014,470	0.81	2
WILLIAMS	 1,738,413	0.699	3
JONES	 1,544,427	0.621	4
BROWN	 1,544,427	0.621	5
DAVIS	 1,193,760	0.48	6
MILLER	 1,054,488	0.424	7
WILSON	 843,093	0.339	8
MOORE	 775,944	0.312	9
TAYLOR	 773,457	0.311	10
End file
1. Smith
2. Johnson
3. Williams
4. Jones
5. Brown
6. Davis
7. Miller
8. Wilson
9. Moore
10. Taylor

View Diff

1,11c1,10
< Surname  	Approx Number  	% Frequency  	Rank  
< SMITH	 2,501,922	1.006	1
< JOHNSON	 2,014,470	0.81	2
< WILLIAMS	 1,738,413	0.699	3
< JONES	 1,544,427	0.621	4
< BROWN	 1,544,427	0.621	5
< DAVIS	 1,193,760	0.48	6
< MILLER	 1,054,488	0.424	7
< WILSON	 843,093	0.339	8
< MOORE	 775,944	0.312	9
< TAYLOR	 773,457	0.311	10
---
> 1. Smith
> 2. Johnson
> 3. Williams
> 4. Jones
> 5. Brown
> 6. Davis
> 7. Miller
> 8. Wilson
> 9. Moore
> 10. Taylor

Solutions

The best way to learn is to practice. Below, you will find some of the solutions other golfers have entered. To unlock higher ranked solutions, submit your own entry which does as well or better than the solutions you can currently see - climb the ladder!

Check out these helpful resources to improve your Vim skills... Game on.

Unlock 163 remaining solutions by signing in and submitting your own entry
#164 Mike Cooper / @mythmon - Score: 193 - 12/29/10 @ 23:38
dd:%s/\(.*\)\t.(<BS>*\t.*\t\(.*\)$/\2. \1/g<CR>Vkkkkkkkkkkkk:%s/[<BS>\([A-Z]\)\(.*\)/\1\L\2/<CR>:<Up><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><Left><BS><BS><BS><BS><BS><CR>:wq<CR>

0 comments


Created by: @lionelyoung

164 active golfers, 520 entries

Leaderboard (lowest score wins):
54
#151 - theshadowhost / @theshadowhost

12/29/2010 at 01:53PM

54
#152 - Luke Ledet / @lukeledet

12/29/2010 at 03:21PM

55
#153 - Justin Knag / @justinknag

08/30/2014 at 01:15AM

58
#154 - Aaron Bull Schaefer / @elasticdog

12/29/2010 at 03:44PM

58
#155 - Chris Doble / @chrisdoble

12/30/2010 at 12:27AM

59
#156 - Duda Dornelles / @dudadornelles

12/29/2010 at 12:22AM

65
#157 - Arto Vuori / @dhpe

08/30/2012 at 08:28PM

69
#158 - ivarv / @ivarv

12/29/2010 at 08:38AM

88
#159 - jonlorusso / @jonlorusso

12/30/2010 at 12:04AM

106
#160 - Josh / @karlw00t

12/29/2010 at 01:03AM

144
#161 - drio / @drio

12/31/2010 at 01:03PM

168
#162 - Stephen Paul Weber / @singpolyma

12/29/2010 at 02:33AM

182
#163 - Jurica / @Jurica34581259

12/12/2018 at 11:48AM

193
#164 - Mike Cooper / @mythmon

12/29/2010 at 11:38PM