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 5ba020f91abf2d000951055c

Com(m)a Trouble

Someone was real stupid when placing his commas. Can you fix it?

Start file
,0,1,2,3,4,5,6,7,89
,1,2,3,4,5,6,7,8,90
,2,3,4,5,6,7,8,9,01
,3,4,5,6,7,8,9,0,12
,4,5,6,7,8,9,0,1,23
56,7,8,9,0,1,2,3,4,
67,8,9,0,1,2,3,4,5,
78,9,0,1,2,3,4,5,6,
89,0,1,2,3,4,5,6,7,
90,1,2,3,4,5,6,7,8,
End file
0,1,2,3,4,5,6,7,8,9
1,2,3,4,5,6,7,8,9,0
2,3,4,5,6,7,8,9,0,1
3,4,5,6,7,8,9,0,1,2
4,5,6,7,8,9,0,1,2,3
5,6,7,8,9,0,1,2,3,4
6,7,8,9,0,1,2,3,4,5
7,8,9,0,1,2,3,4,5,6
8,9,0,1,2,3,4,5,6,7
9,0,1,2,3,4,5,6,7,8

View Diff

1,10c1,10
< ,0,1,2,3,4,5,6,7,89
< ,1,2,3,4,5,6,7,8,90
< ,2,3,4,5,6,7,8,9,01
< ,3,4,5,6,7,8,9,0,12
< ,4,5,6,7,8,9,0,1,23
< 56,7,8,9,0,1,2,3,4,
< 67,8,9,0,1,2,3,4,5,
< 78,9,0,1,2,3,4,5,6,
< 89,0,1,2,3,4,5,6,7,
< 90,1,2,3,4,5,6,7,8,
---
> 0,1,2,3,4,5,6,7,8,9
> 1,2,3,4,5,6,7,8,9,0
> 2,3,4,5,6,7,8,9,0,1
> 3,4,5,6,7,8,9,0,1,2
> 4,5,6,7,8,9,0,1,2,3
> 5,6,7,8,9,0,1,2,3,4
> 6,7,8,9,0,1,2,3,4,5
> 7,8,9,0,1,2,3,4,5,6
> 8,9,0,1,2,3,4,5,6,7
> 9,0,1,2,3,4,5,6,7,8

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 394 remaining solutions by signing in and submitting your own entry
#395 Matej Stuchlik / @mstuchli - Score: 159 - 06/06/19 @ 16:21
<C-V>jjjjxpl.u.uuu<C-V>jjjj<Esc><Esc>kkkkqq<C-V>jjjjxpql@ql@@l@@l@@l@@l@@l@@l@@jjjjjhhhhhhhhhhhhhhhhhhhhllqq<C-V>jjjjxhhpqlll@qlll@@lll@@lll@@lll@@lll@@lll@@lll@@u@@u<C-V>jjjjxhp<Esc>:w<CR>:wqa<CR>

0 comments


Created by: @DustVoice

395 active golfers, 1699 entries

Leaderboard (lowest score wins):
12
#31 - Darren Weston / @dazWestonUK

04/21/2019 at 10:45AM

12
#32 - Grant / @grant_7788

04/26/2019 at 02:27PM

12
#33 - Kai.Li / @KaiLi19

04/28/2019 at 06:52AM

12
#34 - Fiffy / @sr21486642

05/17/2019 at 08:01AM

12
#35 - David McDonald / @dmcdona

05/19/2019 at 04:06AM

12
#36 - Foo Bar / @foobar01123

06/02/2019 at 06:43AM

12
#37 - Ben M / @Sweet_Scientist

06/06/2019 at 09:23AM

12
#38 - Evans Code Rants / @EvansCodeRants

06/06/2019 at 01:24PM

12
#39 - Sondre Lunde / @SondreSL

06/06/2019 at 04:50PM

12
#40 - Sæther / @baltre1

06/06/2019 at 04:51PM

12
#41 - Zevurari / @zevurari

06/06/2019 at 08:10PM

12
#42 - Will Durney / @WillDurney

06/06/2019 at 08:20PM

12
#43 - Cory Mainwaring / @Olreich

06/06/2019 at 08:53PM

12
#44 - Mike Fang / @MikeFang20

06/07/2019 at 01:19AM

12
#45 - Mike Clarke / @clarkema

06/07/2019 at 12:10PM

12
#46 - Romain Bitard / @RBitard

06/07/2019 at 01:15PM

12
#47 - deurzen / @devrzen

06/08/2019 at 04:10PM

12
#48 - NGM / @gmnimrod1

06/10/2019 at 01:14PM

12
#49 - Parker Vaughn / @__holdand__

06/11/2019 at 03:32PM

12
#50 - duyanh.y4n.pham / @PhamY4n

06/11/2019 at 08:15PM

12
#51 - John Braxler / @braxler

06/19/2019 at 05:26PM

12
#52 - Neil Struthers / @struthersneil

07/17/2019 at 12:44AM

13
#53 - Jon Krause / @jkrause314

09/18/2018 at 05:39AM

13
#54 - Smylers / @Smylers2

09/18/2018 at 08:48AM

13
#55 - Timothée Gauthier / @zmf_tim

09/18/2018 at 08:00PM

13
#56 - Epecb / @BceEpecb

09/19/2018 at 05:21PM

13
#57 - Yudi Matsuzake / @yudimatsuzake

09/19/2018 at 11:37PM

13
#58 - Harm te Hennepe / @HrmtH

09/20/2018 at 11:29AM

13
#59 - Saki Gw / @Sakigw

09/20/2018 at 01:28PM

13
#60 - Gayan Munasinghe / @gayanm

09/21/2018 at 11:40PM