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

Solve the Sokoban

A wink for all Vimgolfers that play Nethack too.

Start file
-------- ------
|<|@...---....|
|^|-.00....0..|
|^||..00|.0.0.|
|^||....|.....|
|^|------0----|
|^|    |......|
|^------......|
|..^^^^0000...|
|??-----......|
----   --------
End file
-------- ------
|@|>...---....|
|.|-..........|
|.||..00|.....|
|.||....|.....|
|.|------.----|
|.|    |......|
|.------......|
|.............|
|..-----......|
----   --------

View Diff

2,10c2,10
< |<|@...---....|
< |^|-.00....0..|
< |^||..00|.0.0.|
< |^||....|.....|
< |^|------0----|
< |^|    |......|
< |^------......|
< |..^^^^0000...|
< |??-----......|
---
> |@|>...---....|
> |.|-..........|
> |.||..00|.....|
> |.||....|.....|
> |.|------.----|
> |.|    |......|
> |.------......|
> |.............|
> |..-----......|

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 73 remaining solutions by signing in and submitting your own entry
#74 Solomon White / @rubysolo - Score: 53 - 01/03/11 @ 00:26
:%s/0/./g<CR>:%s!\^!.!g<CR>jls.<Esc>l.2Gls@<Esc>lls><Esc>jjlll2s00<Esc>:wq<CR>

0 comments


Created by: @0x00C0FFEE

74 active golfers, 177 entries

Leaderboard (lowest score wins):
25
#1 - Federico Galassi / @federicogalassi

10/02/2011 at 12:53PM

25
#2 - Conner McDaniel / @connermcd

11/29/2012 at 05:24PM

25
#3 - Zapata / @Incredible_JFP

03/21/2014 at 06:16PM

25
#4 - Jon Krause / @jkrause314

01/29/2016 at 11:54PM

25
#5 - trx / @trxdbg

10/18/2016 at 01:22AM

25
#6 - ParasamGateZero / @ParasamGateZero

01/25/2018 at 11:09PM

25
#7 - 刘宏亮 / @AkeyCoy

09/26/2022 at 04:38AM

25
#8 - Peppa Pig / @PeppaPigSg

06/02/2024 at 09:56AM

25
#9 - nickGPT / @nickandbro

08/28/2024 at 11:26PM

26
#10 - Urtica dioica / @udioica

12/12/2012 at 11:13AM

26
#11 - John Braxler / @braxler

08/22/2014 at 03:28PM

27
#12 - tmr / @tmr314

09/10/2012 at 02:29PM

27
#13 - Trevor Powell / @DoomedBunnies

03/20/2013 at 04:54AM

29
#14 - Kerson Hsiao / @KersonHsiao

07/24/2012 at 03:05PM

29
#15 - Matt / @mcr05

12/30/2014 at 09:39PM

30
#16 - dominique pellé / @vimgolfisto

01/02/2011 at 03:54PM

30
#17 - Balkoth / @_Balkoth_

01/02/2011 at 04:01PM

30
#18 - Ben Lenarts / @benlenarts

01/02/2011 at 09:56PM

30
#19 - Pete Johns / @johnsyweb

01/02/2011 at 11:44PM

30
#20 - Wei Dai / @clvv42

01/03/2011 at 12:24AM

30
#21 - derp derp / @derp__

01/06/2011 at 10:31AM

30
#22 - Ujjwol Lamichhane / @Ujjwol

01/07/2011 at 10:37AM

30
#23 - nicholas a. evans / @nick_evans

01/07/2011 at 07:27PM

30
#24 - Francisco Dibar / @frandibar

01/12/2011 at 01:45PM

30
#25 - Oleg Roshupkin / @jjjahson

01/19/2011 at 10:24AM

30
#26 - Steve Morrow / @yawmark

01/31/2011 at 05:17PM

30
#27 - Brendan Taylor / @beect

04/26/2011 at 10:20PM

30
#28 - Dragan Cvetinovic / @kawkafi

05/22/2011 at 03:14PM

30
#29 - Jam / @jam00_bcn

06/18/2011 at 03:24PM

30
#30 - Junfeng / @junfeng

07/26/2011 at 09:59AM