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 53c66c482b4166000226bbee

Don't know what this is

Replace contents of brackets with matching number of spaces. Don't ask what the format's supposed to be.

Start file
[1:0]
[0:1]
[1:100]
[0:100]
End file
[   ]
[   ]
[     ]
[     ]

View Diff

1,4c1,4
< [1:0]
< [0:1]
< [1:100]
< [0: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 518 remaining solutions by signing in and submitting your own entry
#519 luffy / @raxcoi - Score: 75 - 08/01/14 @ 13:29
:<Up><Up><Up>%s/[^\[\]]*/\=repeat()/g<Left><Left><Left><Left><Left><Left><Left><Left><Left><Right><Right><Right><Right><Right><Right><Right><Left>' ', strlen()<Left>submatch(0)<CR>:wq<CR>

0 comments


Created by: @udioica

519 active golfers, 1730 entries

Leaderboard (lowest score wins):
14
#241 - Omer Lachish / @rauchy

07/20/2014 at 11:26AM

14
#242 - joomy / @cattheory

07/20/2014 at 07:33PM

14
#243 - Patrick Negri / @patricknegri

07/20/2014 at 09:20PM

14
#244 - Tui Kiken / @TuiKiken

07/23/2014 at 12:34PM

14
#245 - pip_elekiban / @pip_elekiban

07/25/2014 at 07:28AM

14
#246 - Lieven Keersmaekers / @LievenKeersmaek

07/27/2014 at 05:44PM

14
#247 - Javier Blanco / @jbgutierrez

07/29/2014 at 10:00PM

14
#248 - Clinton シ / @iblamefish

07/30/2014 at 08:05PM

14
#249 - Patrick Pitoscia / @Patrick03960431

08/03/2014 at 04:01AM

14
#250 - Jeremy Ruten / @yjerem

08/03/2014 at 08:42AM

14
#251 - Stefan Schmidt / @stafue

08/08/2014 at 01:18PM

14
#252 - Harald H / @metellius

08/21/2014 at 08:34PM

14
#253 - Fnord Everywhere / @FnordE

08/22/2014 at 07:18AM

14
#254 - Florian Lücke / @CannibalGorilla

08/26/2014 at 09:07AM

14
#255 - See BEAMs through walls / @hauleth

09/02/2014 at 10:00PM

14
#256 - Robbie Clarken / @robbieclarken

09/07/2014 at 10:38PM

14
#257 - mnx / @mnxx

09/10/2014 at 12:48PM

14
#258 - Michael Comerford / @MComerford1

09/16/2014 at 12:31AM

14
#259 - Patrick Oscity / @der_padde

09/16/2014 at 02:51PM

14
#260 - evimgolf / @evimgolf

09/21/2014 at 07:42PM

14
#261 - Antonio De Luna / @Tony_1917

09/24/2014 at 06:37AM

14
#262 - Jakob / @jajob

09/29/2014 at 06:30PM

14
#263 - Eric Kever / @codeoverlode

09/29/2014 at 10:33PM

14
#264 - Viktor Lindström / @ViktorLindstr_m

09/30/2014 at 09:28PM

14
#265 - Mihir / @mihirgogate

10/04/2014 at 07:24AM

14
#266 - Marcelo Montu / @_mMontu_

10/29/2014 at 05:31PM

14
#267 - eBrnd / @eBrnd

11/02/2014 at 12:24PM

14
#268 - w1zeman1p / @wizemanip

11/09/2014 at 07:45PM

14
#269 - Davit Samvelyan / @DavitSamvelyan

11/13/2014 at 02:01PM

14
#270 - Jan Novak / @odpadnimail

11/19/2014 at 03:44AM