Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Leaderboard, Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put 4dddc7c1ed7380000100000d

Multiplication table.

Create a multiplication table.

Start file
1
End file
1   2   3   4   5   6   7   8   9   10
2   4   6   8   10  12  14  16  18  20
3   6   9   12  15  18  21  24  27  30
4   8   12  16  20  24  28  32  36  40
5   10  15  20  25  30  35  40  45  50
6   12  18  24  30  36  42  48  54  60  
7   14  21  28  35  42  49  56  63  70
8   16  24  32  40  48  56  64  72  80
9   18  27  36  45  54  63  72  81  90
10  20  30  40  50  60  70  80  90  100

View Diff

1c1,10
< 1
---
> 1   2   3   4   5   6   7   8   9   10
> 2   4   6   8   10  12  14  16  18  20
> 3   6   9   12  15  18  21  24  27  30
> 4   8   12  16  20  24  28  32  36  40
> 5   10  15  20  25  30  35  40  45  50
> 6   12  18  24  30  36  42  48  54  60  
> 7   14  21  28  35  42  49  56  63  70
> 8   16  24  32  40  48  56  64  72  80
> 9   18  27  36  45  54  63  72  81  90
> 10  20  30  40  50  60  70  80  90  100

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 44 remaining solutions by signing in and submitting your own entry
#45 h_east (DDD ready) / @h_east - Score: 98 - 05/26/11 @ 12:29
q:2afor y in range(1,10)|<Esc>FyrxAlet@A=printf("%-4d",y*x)<Esc>2a|endfo<Esc>bil<C-P>@A='<C-V><NL>'|<Esc><CR>s<C-R>a<C-H><C-H><Esc>k<C-V>H$x5ja  <Esc>ZZ

0 comments

#46 Christopher Erin / @Chris__Erin - Score: 104 - 09/20/11 @ 18:03
Y9p:%s/\d$/\=submatch(0)."<Tab>".(submatch(0)+1)<CR>8@:6GA<Tab><Esc>:%s/\d/\=submatch(0)*line(".")/g<CR>:se ts=4 et|ret|x<CR>

0 comments

#47 Torben Rasmussen / @rasmustorben - Score: 116 - 08/15/11 @ 16:03
qqyyp<C-A>q8@qgg10Jqayyp<C-A>w2<C-A>w3<C-A>w4<C-A>w5<C-A>w6<C-A>w7<C-A>w8<C-A>w9<C-A>w10<C-A>q8@a:%s/\<\(.\)\>/\1  /g<NL>:<Up><Left><Left><Left><BS><Left><Left><Left><Left><Left><Left><Left>.<NL>6ggA<Esc>gg$<C-V>jjjjjjjjd6ggA  <Esc>ZZ

0 comments

#48 mightyfoo / @mightyfoo - Score: 124 - 05/26/11 @ 10:24
Y9p<CR>:%s/\v(\d+(<Tab>+))*(\d+)/\=submatch(0)."<Tab>".(submatch(3)+1)<CR>6GA<Tab><Esc>8@:::%s/\v(\d+)/\=line(".")*submatch(0)/g|se ts=4 et|ret|x<CR>

0 comments

#49 Mathias Fussenegger / @mfussenegger - Score: 132 - 06/06/11 @ 21:12
Y9p<CR>:5<BS>%s<BS>s/\v(\d+(<Tab>+))*(\d+)/\=submatch(0)."<Tab>".(submatch(3)+1)<CR>6GA<Tab><Esc>8@:::<BS>%s/\v(\d+)/\=line(".")*submatch(0)/g|se ts=4 et|ret<0xc2><0xab><BS>|x<CR>

0 comments

#50 Kevin Stewart / @stewkev - Score: 140 - 02/06/12 @ 01:25
Y9p:s<BS><C-]>s<BS><BS>%s/\v(\d+(<Tab>+))*(\d+)/\=submatch(0)."<Tab>><BS>".(submatch(3)+1)<CR>6GA<Tab><Esc>8@::::%d<BS>s/\v(\d+)/\=line(".")*submea<BS><BS>atch(0)/g|se ts=5<BS>4 et|ret|x<CR>

0 comments

#51 Bodaniel Jeanes / @bjeanes - Score: 143 - 06/01/11 @ 00:56
Y9p:%s/\v(\d+(<Tab>|<C-H>+))*(\d+_<C-H>)/\=submatch(0)."<Tab>".(submatch(3)+1)<CR>6GA<Tab><Esc>8@:<CR>:%s/\v(\d+_/\=<C-H><C-H><C-H><C-H>(<C-H>)/\=line(".")*submatch(0)/g|se ts=4 et|ret}|x<C-H><C-H><C-H>|x<CR>

0 comments

#52 Joey Geralnik / @jgeralnik - Score: 148 - 12/20/11 @ 13:45
x:for i in range(1,10)<CR>for j in range(1,10)<CR>if i*j<10<CR>put=i*j.'   '<CR>elseif i*j<100<CR>put=i*j.'  '<CR>else<CR>put='100'<CR>endif<CR>en<Tab><CR>en<Tab><CR>qqV9kJkxxq9@qdd5jA  <Esc>ZZ

0 comments

#53 Dan Masquelier / @danmasq - Score: 162 - 07/01/11 @ 08:22
x:for i in range(1,10)|for j in range(1,10)|if i*j<10|put=i*j.'   '|elseif i*j>=10 && i*j<100|put=i*j.'  '|else|put='100'|endif|end<Tab>|end<Tab><CR>qvV9kJkxxq9@vdd5j$a  <Esc>ZZ

0 comments

#54 Robert Robotter / @robrob12 - Score: 203 - 05/26/11 @ 09:07
:func! A()<CR>let o=''<CR>for x in range(1, 10)<CR>for y in range(1, 10)<CR>let m=x*y<CR>if m > 9<CR>let m=m."  "<CR>el<CR>let m=m."   "<CR>endif<CR>let o=o.m<CR>endfo<CR>let o=o."\n"<CR>endfo<CR>retu o<CR>endfunc<CR>i<C-R>=A()<CR><Esc>dd{$<Left><C-V>G$xG$i0<Esc>:6<CR>$i<Right>  <Esc>:x<CR>

0 comments

#55 Arton0306 / @Arton0306 - Score: 310 - 12/18/11 @ 13:15
:se ts=4 et<NL>i<Tab><BS><BS><BS><BS><Right><Tab>2<Tab>3<Tab>4<Tab>5<Tab>6<Tab>7<Tab>8<Tab>9<Tab>10<NL>2<Tab>4<Tab>6<Tab>8<Tab>10<Tab>12<Tab>14<Tab>16<Tab>18<Tab>20<NL>3<Tab>6<Tab>9<Tab>12<Tab>15<Tab>18<Tab>21<Tab>24<Tab>27<Tab>30<NL>4<Tab>8<Tab><End><k1><k2><Tab><k1><k6><Tab><k2><k0><Tab><k2><k4><Tab><k2><k8><Tab><k3><k2><Tab><k3><k6><Tab><k4><k0><NL><k5><Tab><k1><k0><Tab><k1><k5><Tab><k2><k0><Tab><k2><k5><Tab><k3><k0><Tab><k3><k5><Tab><k4><k0><Tab><k4><k5><Tab><k5><k0><NL><k6><Tab><k1><k2><Tab><k1><k8><Tab><k2><k4><Tab><k2><BS><k3><k0><Tab><k3><k4><Tab><BS><BS><BS><k6><Tab><k4><k2><Tab><k4><k8><Tab><k5><k4><Tab><k6><k0>  <NL><k7><Tab><k1><k4><Tab><k2><k1><Tab><k2><k8><Tab><k3><k5><Tab><k4><k2><Tab><k4><k9><Tab><k5><k6><Tab><k6><k3><Tab><k7><k0><NL><k8><Tab><k1><k6><Tab><k2><k4><Tab><k3><k2><Tab><k4><k0><Tab><k4><k8><Tab><k5><k6><Tab><k6><k4><Tab><k7><k2><Tab><k8><k0><NL><k9><Tab><k1><k8><Tab><k2><k7><Tab><k3><k6><Tab><k4><k5><Tab><k5><k4><Tab><k6><k4><BS><k3><Tab><k7><k2><Tab><k8><k1><Tab><k9><k0><NL><k1><k0><Tab><k2><k0><Tab><k3><k0><Tab><k4><k0><Tab><k5><k0><Tab><k6><k0><Tab><k7><k0><Tab><k8><k0><Tab><k9><k0><Tab><k1><k0><k0><Esc>ZZ

0 comments

#56 Ben Sherman / @bensherman - Score: 395 - 10/18/11 @ 23:51
A   2   3   4   5   6   7   8   9   10<CR>2   4   6   8   10  12  14  16  18  20<CR>3   6   9   12  15  18  21  24  27  30<CR>4   8   12  16  20  24  28  32  36  40<CR>5   10  15  20  25  30  35  40  45  50<CR>6   12  18  24  30  36  42  48  54  60  <CR>7   14  21  28  35  42  49  56  63  70<CR>8   16  24  32  40  48  56  64  72  80<CR>9   18  27  36  45  54  63  72  81  90<CR>10  20  30  40  50  60  70  80  90  100<Esc>ZZ

0 comments

Created by: @connermcd

56 active golfers, 168 entries

Leaderboard (lowest score wins):
29
#1 - Urtica dioica / @udioica

06/25/2015 at 11:48PM

37
#2 - John Braxler / @braxler

08/01/2014 at 07:15PM

42
#3 - Kerson Hsiao / @KersonHsiao

08/20/2012 at 05:09AM

42
#4 - Conner McDaniel / @connermcd

10/30/2012 at 04:41PM

42
#5 - Petro Тrouq / @zulolosi

05/08/2013 at 07:05PM

49
#6 - John Anderson / @opejn

12/24/2011 at 01:02AM

49
#7 - Tim Chase / @gumnos

01/03/2012 at 04:07PM

49
#8 - Abdel Said / @abdelsaid

04/07/2012 at 04:20PM

49
#9 - Benoit Mortgat / @Benoit_Mortgat

06/06/2012 at 08:40PM

50
#10 - You-Siang Lin / @yslinnctu

11/29/2011 at 02:49AM

50
#11 - Jaime A. Sánchez / @jashbeta

12/21/2011 at 09:30PM

51
#12 - not so punk :] / @notsopunk

06/19/2011 at 07:34AM

51
#13 - Justin Love / @wondible

09/18/2011 at 10:20PM

52
#14 - xhtmlforum / @xhtmlforum

05/26/2011 at 08:53AM

52
#15 - Stephen Morrow / @yawmark

05/26/2011 at 01:54PM

52
#16 - Hu Junfeng / @junfeng

08/05/2011 at 10:33AM

52
#17 - derp derp / @derp__

01/02/2012 at 06:23PM

53
#18 - Utkarsh Kukreti / @utkarshkukreti

05/26/2011 at 10:46PM

61
#19 - vimja / @vimja666

11/01/2011 at 12:33AM

64
#20 - bmamax / @bmamax

01/14/2012 at 02:08PM

64
#21 - Eric Andres / @eric_m_andres

12/05/2012 at 05:34PM

68
#22 - Jomo / @yoyoyojomo

03/14/2012 at 08:34AM

70
#23 - Ingo / @ist3fani

08/07/2013 at 03:25PM

71
#24 - Jer Wilson / @superjercom

10/29/2011 at 01:42AM

73
#25 - Nonayo Biznast / @NonayoBiznast

09/10/2011 at 10:11AM

74
#26 - Johan Sveholm / @rymdtjuren

06/24/2011 at 12:27AM

74
#27 - learninghang / @learninghang

04/14/2012 at 04:13PM

74
#28 - Marcin Sza / @coot_

10/26/2013 at 08:55AM

75
#29 - arno renevier / @dadadiblog

03/18/2012 at 07:14PM

77
#30 - Pasha Klets / @p01nt

05/26/2011 at 08:50AM

77
#31 - Drew Olson / @drewolson

06/01/2011 at 12:58AM

78
#32 - Dave / @zzdave13

07/16/2011 at 10:09AM

78
#33 - Daniel Lundin / @danielundin

05/07/2012 at 01:59PM

80
#34 - Justin Hale / @jxl

05/26/2011 at 09:25AM

82
#35 - Dave Lyon / @daveisonthego

06/01/2011 at 12:55AM

82
#36 - 無ん垢の叫び / @john_ababa

03/10/2012 at 03:59PM

83
#37 - Jason Wolf / @zephyr_wolf

11/16/2012 at 08:57PM

84
#38 - Jean-Rene David / @jeanrenedavid

06/11/2011 at 07:01PM

85
#39 - Josh Davey / @joshuadavey

06/01/2011 at 12:59AM

85
#40 - Gabriel Barta / @gbarta

12/03/2011 at 01:10PM

86
#41 - Oliver Christ / @0liverChrist

11/08/2013 at 11:28PM

89
#42 - Renat Aksitov / @Korvin79

02/23/2012 at 11:07AM

89
#43 - US Dollar Price / @USDollarPrice

11/08/2013 at 12:26AM

91
#44 - Paul Hinze / @phinze

06/01/2011 at 12:53AM

98
#45 - h_east (DDD ready) / @h_east

05/26/2011 at 12:29PM

104
#46 - Christopher Erin / @Chris__Erin

09/20/2011 at 06:03PM

116
#47 - Torben Rasmussen / @rasmustorben

08/15/2011 at 04:03PM

124
#48 - mightyfoo / @mightyfoo

05/26/2011 at 10:24AM

132
#49 - Mathias Fussenegger / @mfussenegger

06/06/2011 at 09:12PM

140
#50 - Kevin Stewart / @stewkev

02/06/2012 at 01:25AM

143
#51 - Bodaniel Jeanes / @bjeanes

06/01/2011 at 12:56AM

148
#52 - Joey Geralnik / @jgeralnik

12/20/2011 at 01:45PM

162
#53 - Dan Masquelier / @danmasq

07/01/2011 at 08:22AM

203
#54 - Robert Robotter / @robrob12

05/26/2011 at 09:07AM

310
#55 - Arton0306 / @Arton0306

12/18/2011 at 01:15PM

395
#56 - Ben Sherman / @bensherman

10/18/2011 at 11:51PM