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

Search and Replace 0

Replace every instance of 'aaa' with 'xaaax'.

Start file
aaa
aab
abb
bbb
aaa
aab
abb
bbb
aaa
aab
abb
bbb
aaa
aab
abb
bbb
aaa
aab
abb
bbb
End file
xaaax
aab
abb
bbb
xaaax
aab
abb
bbb
xaaax
aab
abb
bbb
xaaax
aab
abb
bbb
xaaax
aab
abb
bbb

View Diff

1c1
< aaa
---
> xaaax
5c5
< aaa
---
> xaaax
9c9
< aaa
---
> xaaax
13c13
< aaa
---
> xaaax
17c17
< aaa
---
> xaaax

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 1313 remaining solutions by signing in and submitting your own entry
#1314 Richard Kaufman / @sparragus - Score: 96 - 12/29/10 @ 14:56
:/<BS>%/<Left><Left><Right>s<Right>'aa'<Left>a<Right>/<Left><Left>x<Left><Right><Right><BS><BS><Left><Left><Left><BS><Right><Right><Right><Right><Right>xaaax/g<CR>:wq<CR>

0 comments


Created by: @wolever

1314 active golfers, 4058 entries

Leaderboard (lowest score wins):
22
#1261 - Simon Walker / @srwalker101

12/29/2010 at 11:37AM

22
#1262 - Fer Enaf / @0x00C0FFEE

12/29/2010 at 12:44PM

22
#1263 - smokey42 / @smokey42

12/29/2010 at 02:16PM

22
#1264 - David Anguita / @danguita

12/30/2010 at 09:12AM

22
#1265 - arumat / @ryochack

04/24/2011 at 07:41AM

22
#1266 - sorami / @boredoms

04/30/2011 at 09:43PM

22
#1267 - olivier lemoigne / @olivierlemoigne

05/04/2018 at 12:42PM

22
#1268 - Todd Zimmerman / @zimmermant_uw

02/03/2019 at 03:36PM

23
#1269 - Stephen Paul Weber / @singpolyma

12/29/2010 at 02:21AM

23
#1270 - irkenInvader / @irken_Invader

12/29/2010 at 02:45AM

23
#1271 - Aku Kotkavuo / @arkx

12/29/2010 at 02:55AM

23
#1272 - Dominick LoBraico / @pygatea

12/29/2010 at 03:16AM

23
#1273 - vagmi / @vagmi

12/29/2010 at 03:17AM

23
#1274 - Alison Rowland / @arowla

12/29/2010 at 03:34AM

23
#1275 - Eric / @e_harney

12/29/2010 at 03:50AM

23
#1276 - Gordy F / @gordyf

12/29/2010 at 06:52AM

23
#1277 - Brian Buckley / @bbuckley

12/29/2010 at 01:24PM

23
#1278 - Dan Paulus / @dan_paulus

12/29/2010 at 02:45PM

23
#1279 - Gustavo Castro / @gustavocastro

12/29/2010 at 04:48PM

23
#1280 - Carlos Troncoso / @carlostph

12/29/2010 at 10:03PM

23
#1281 - Barthelemy Dagenais / @bartdag

12/30/2010 at 12:51AM

23
#1282 - Babak Pourkazemi / @bpkazemi

04/16/2014 at 02:01AM

24
#1283 - gnuchu / @gnuchu

12/29/2010 at 01:26AM

24
#1284 - eolo999 / @eolo999

12/29/2010 at 01:37AM

24
#1285 - Frank Hui / @frankhui

12/29/2010 at 06:23AM

24
#1286 - Mahesh / @Maheshhhari

08/05/2018 at 02:54PM

25
#1287 - Martin Pugh / @s3krit

12/29/2010 at 01:43AM

25
#1288 - timotheo / @timotheo

12/29/2010 at 05:41AM

25
#1289 - scott / @SetecAstronomy

12/29/2010 at 10:55AM

25
#1290 - ; / @dandwor

02/05/2014 at 01:44PM