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 51cd1be19f3290000200000e

Assign list

Assign list elements to matrix

Start file
A challenge can hide secrets

  M00 =
  M01 =
  M10 =
  M11 =
  M20 =
  M21 = 0
End file
  M[0][0] = 'A'
  M[0][1] = 'challenge'
  M[1][0] = 'can'
  M[1][1] = 'hide'
  M[2][0] = 'secrets'
  M[2][1] = 0

View Diff

A challenge can hide secrets				      <

  M00 =							      |	  M[0][0] = 'A'
  M01 =							      |	  M[0][1] = 'challenge'
  M10 =							      |	  M[1][0] = 'can'
  M11 =							      |	  M[1][1] = 'hide'
  M20 =							      |	  M[2][0] = 'secrets'
  M21 = 0						      |	  M[2][1] = 0

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 43 remaining solutions by signing in and submitting your own entry
#44 Thiago Alves / townk - Score: 57 - 07/05/13 @ 06:03
:1s/\v(\w+) ?/ '\1'<C-V><CR>/g<CR>k<C-V>gg$d8G$pqa^a[<Right>][<Right>]<Esc>jq5@a6Gd6kZZ

0 comments

#45 lastsseldon / lastsseldon - Score: 57 - 08/18/13 @ 00:02
qqcw''<Esc>PWi<BS><CR><Esc>q4@qk<C-V>gg$d7GA <Esc>p2F0<C-V>6jl:s/\%V./[\0]/g<CR>gg5DZZ

0 comments

#46 Yongho / YONG_HO - Score: 58 - 07/05/13 @ 07:39
:%s/\v(\d)(\d)/[\1][\2]/g<CR>ggA <Esc>^qadw/=$<CR>a ''<Esc>hpxggq4@addZZ

0 comments

#47 ltn614 / ltn614 - Score: 59 - 10/01/15 @ 17:35
:s/\w*/'&'/g|s/ /\r/g<CR><CR><C-V>(I <Esc><C-V>5$d7$pFMqqa[<Right>][<Right>]<Esc>+q5@q5GdggZZ

0 comments

#48 Eric Potter / pottereric - Score: 60 - 12/20/13 @ 16:24
:%s/\d/[&]/g<CR>:3,7s/$/ ''<CR>//<BS>''<CR>qqggdwnpxq4@qis<Esc>ggddG$xhhlxZZ

0 comments

#49 Aaron Bieber / aaronbieber - Score: 61 - 07/14/13 @ 11:40
i <Esc>:s/\S\+/'&'<C-V><CR>/g<CR>5k<C-V>4j$x/=<CR>pk5dk:%s/\v(\d)(\d)/[\1][\2]/<CR>ZZ

0 comments

#50 Jacob Straszynski / jacobstr - Score: 61 - 07/28/13 @ 22:01
qqdiw2j$a ''<Esc>P"Addggq4@q2j"APkddkxxxx/\d<CR>qqxi[]<Esc>Pnq11@q:w<CR>:q<CR>

0 comments

#51 Mauro Persano / fzort - Score: 61 - 11/20/14 @ 21:08
3Gqal2s[][]<Esc>PX2hPA ''<Esc>ma1Gdw`aPx+q4@al2s[][]<Esc>PX2hPk$is<Esc>1GddZZ

0 comments

#52 mooqual / mooqual - Score: 67 - 06/30/13 @ 04:18
:s/\(\w*\) */'\1'<C-V><CR>/g<CR>gg<C-V>$4jX7jA <Esc>p2kdggjwqaa[<Esc>la][<Esc>la]<Esc>0jwq5@a:wq<CR>

0 comments

#53 James Scriven / JamesDScriven - Score: 68 - 07/06/13 @ 19:49
/M<CR><C-V>GA[<Esc>ll<C-V>GA][<Esc>E<C-V>GA]<Esc>A 'A'<Esc>jA 'c<C-N>'<Esc>jA 'can'<Esc>jA 'h<C-N>'<Esc>jA 's<C-N>'<Esc>ggDddZZ

0 comments

#54 moo goo / m00g000 - Score: 73 - 07/01/13 @ 15:28
qwdw/=$<CR>pggq@w@@@@@@dd:%s/\vM(\d)(\d)/M[\1][\2]<CR>:%s/\v\=(\w+) */= '\1'<CR>ZZ

zulolosi: Hi! it doesn't need M, only this :%s/\v(\d)(\d)/[\1][\2]

1 comment

Created by: zulolosi

54 active golfers, 145 entries

Leaderboard (lowest score wins):
30
#1 - Bradd Szonye / bszonye

07/10/2013 at 09:19PM

30
#2 - Petro Тrouq / zulolosi

09/17/2013 at 06:54PM

30
#3 - John Braxler / braxler

04/18/2014 at 03:14PM

30
#4 - Jon Krause / jkrause314

01/17/2016 at 09:03AM

31
#5 - Woojung Kim 김우중 / _kimwz

07/12/2013 at 03:51AM

31
#6 - Forrest Zeisler / fzeisler

07/25/2013 at 12:49AM

31
#7 - Ben Zittlau / benzittlau

07/28/2013 at 05:16PM

31
#8 - Felix Stridsberg / FelixStridsberg

08/03/2013 at 03:17PM

31
#9 - Urtica dioica / udioica

11/13/2013 at 05:28PM

31
#10 - Nathan Wallace / nathanmwallace

11/27/2013 at 04:23PM

32
#11 - Steve Tjoa / stevetjoa

07/03/2013 at 06:03PM

32
#12 - ———đίxίє—flαтlίиє——— / _dixie_flatline

07/21/2013 at 01:27AM

32
#13 - _ky_ / ultimate_ky

08/13/2013 at 10:38PM

32
#14 - Roman Charushin / lompee

08/21/2013 at 10:50AM

33
#15 - Andrew Noyes / seyonwerdna

07/08/2013 at 06:55AM

34
#16 - James Davis / tripvg

06/28/2013 at 09:59PM

34
#17 - Casey Dwyer / caseydwyer

10/30/2013 at 09:00AM

34
#18 - jimauthors / jimauthors

02/12/2014 at 01:59AM

35
#19 - Lluís Mª Bosch / LluisMa

06/30/2013 at 01:22AM

35
#20 - Volodymyr / vkrest

07/14/2013 at 10:14PM

36
#21 - Stephen Drodge / sjdrodge

09/29/2013 at 10:55PM

37
#22 - powertomato / powertomato

06/28/2013 at 10:35PM

37
#23 - Dom Armstrong / dom_cycleface

06/30/2013 at 09:45PM

39
#24 - gary.klindt@googlema / garstekli

11/29/2013 at 12:15AM

40
#25 - Tullio Facchinetti / toolleeo

07/24/2013 at 10:34AM

40
#26 - Ingo / ist3fani

07/27/2013 at 02:51PM

44
#27 - Nikolay Frantsev / Shutnik

02/04/2014 at 10:11AM

44
#28 - Joonas Pihlajamaa / jokkebk

03/15/2014 at 10:15AM

45
#29 - Timothée Gauthier / zmf_tim

07/09/2013 at 11:51AM

46
#30 - Carlos A Henríquez Q / lagunex

01/19/2015 at 12:16PM

48
#31 - Nathan / NathanHarperoni

07/19/2013 at 01:12PM

49
#32 - RobertT / techrt2050

07/14/2013 at 09:52AM

49
#33 - brett / brettyukich

09/20/2013 at 12:59AM

49
#34 - Domingue Justin / _jdomingue

12/30/2013 at 06:28PM

51
#35 - Jason Davidson / aka_lingy

08/24/2013 at 10:48PM

51
#36 - nona urbiz / nospampleasemam

09/28/2013 at 08:25AM

52
#37 - newton / newtonsmartt

10/16/2013 at 02:16AM

52
#38 - evilmoe ☮ / evilmoe

11/10/2013 at 10:53AM

53
#39 - Tom Gould / tomgould92

07/16/2013 at 11:23PM

54
#40 - cj / cj01101

08/04/2013 at 04:01AM

54
#41 - Ram Tamtam / ramtamtamtam

07/01/2014 at 08:26AM

55
#42 - Roland Schatz / fl_Overmind

07/14/2013 at 11:48PM

55
#43 - Andrew Crites / ExplosionPills

09/13/2013 at 01:43AM

57
#44 - Thiago Alves / townk

07/05/2013 at 06:03AM

57
#45 - lastsseldon / lastsseldon

08/18/2013 at 12:02AM

58
#46 - Yongho / YONG_HO

07/05/2013 at 07:39AM

59
#47 - ltn614 / ltn614

10/01/2015 at 05:35PM

60
#48 - Eric Potter / pottereric

12/20/2013 at 04:24PM

61
#49 - Aaron Bieber / aaronbieber

07/14/2013 at 11:40AM

61
#50 - Jacob Straszynski / jacobstr

07/28/2013 at 10:01PM

61
#51 - Mauro Persano / fzort

11/20/2014 at 09:08PM

67
#52 - mooqual / mooqual

06/30/2013 at 04:18AM

68
#53 - James Scriven / JamesDScriven

07/06/2013 at 07:49PM

73
#54 - moo goo / m00g000

07/01/2013 at 03:28PM