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

Rural Post

Simple challenge to remove all but the post code on each line

Start file
RD 5 Gore 9775
RD 6 Gore 9776
RD 7 Gore 9777
RD 1 Great Barrier Island 0991
RD 1 Greta Valley 7387
RD 1 Greytown 5794
RD 1 Hamilton 3281
RD 2 Hamilton 3282
End file
9775
9776
9777
0991
7387
5794
3281
3282

View Diff

1,8c1,8
< RD 5 Gore 9775
< RD 6 Gore 9776
< RD 7 Gore 9777
< RD 1 Great Barrier Island 0991
< RD 1 Greta Valley 7387
< RD 1 Greytown 5794
< RD 1 Hamilton 3281
< RD 2 Hamilton 3282
---
> 9775
> 9776
> 9777
> 0991
> 7387
> 5794
> 3281
> 3282

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 850 remaining solutions by signing in and submitting your own entry
#851 yuhung / @koba_taiwan - Score: 349 - 12/25/20 @ 05:31
<Esc><Esc><Esc><0xef><0xbc><0x9a><0xef><0xbc><0x81><Esc><0xe3><0x84><0xa8><0xe3><0x84><0x9c><Esc>jjjjjjj<Esc>:1<BS>1,$s/<BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><Esc>kkkkkkkkkkkkkkk0<Esc><Esc>:%s/&<BS>^.//<CR><Esc>u<Esc>:%s/<Esc><Esc>:q!<BS><BS><BS><Esc>kjjjjjjjjjjjj<Esc><Esc><Esc>kkkkkkkkkkkkkkkkkk<C-V>jjjjjjjllkkkkkkkllllll<Esc>kjjkk0<Esc>:%s/[]<Left>^_s*<Right>(<BS>*<Esc>k<Esc>:s/<BS><BS>%s/<BS><BS><BS>%s/<Esc>kklllllllllllllllllllllljkA<Esc>jjkk<Esc>/<Esc>:s<BS>%s//s<BS><BS>\/s<BS><BS><BS>/s<BS><BS>/t<BS><BS>\_s<BS><BS>s<BS><BS>[]<Left>^\s<Right>*]<BS>\n<BS><BS><BS><Left><Left><Left><Left><Left>*<BS>.*<Right><Right><Right><Right><Left><Left><Right><Right><BS>n<Left><Right><Right>*<BS><Left><Left><Left><BS><Right><Right><BS>s<Right><Left><Left><Left><Left><BS><BS><Right><Right><Right><Right><BS><BS><BS><BS>\s<Left><Left>.*<Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right>//g<CR><Esc>:wq!<CR>

0 comments


Created by: @ctmusicnz

851 active golfers, 3500 entries

Leaderboard (lowest score wins):
16
#601 - Camden Cheek / @ccheek21

12/20/2020 at 04:10AM

16
#602 - Vikram Natarajan / @VikNatr

01/17/2021 at 07:47AM

16
#603 - Codle / @Coolchao

01/19/2021 at 08:03AM

16
#604 - ttauveron / @ttauveron1

01/21/2021 at 12:58AM

16
#605 - Oleg / @Oleg36601324

01/24/2021 at 05:35AM

17
#606 - asdf / @asdf06706771

08/02/2020 at 06:11AM

17
#607 - random_bird9090 / @RBird9090

08/09/2020 at 07:39PM

17
#608 - mario / @mario84586731

08/24/2020 at 02:11PM

17
#609 - Dr Rev J. “I am not a bot!” Kirchartz, KSC, KHS / @JKirchartz

09/09/2020 at 01:09PM

17
#610 - 이종혁 / @BluePaisa

09/17/2020 at 10:01AM

17
#611 - Luke Pafford / @lukep135

09/30/2020 at 02:54PM

17
#612 - AAbraxas / @AAbraxas1

10/07/2020 at 08:56PM

17
#613 - Nima HeydariNasab / @Radio_Nima

10/08/2020 at 12:43PM

17
#614 - Jordan Martel / @martelosaurus

10/13/2020 at 03:17AM

17
#615 - Ahmet Said AK / @asaidak

10/18/2020 at 07:51PM

17
#616 - chewie / @chewie29261190

10/28/2020 at 11:39AM

17
#617 - 0xCEFAEDFE / @umanwizard

10/29/2020 at 06:20PM

17
#618 - Hieu Nguyen / @hieungx

10/30/2020 at 04:28AM

17
#619 - salchint / @salchint

12/04/2020 at 06:19PM

17
#620 - Etienne Tremel / @etiennetremel

12/16/2020 at 07:45PM

17
#621 - kris welsh / @kriswelsh

12/28/2020 at 05:17PM

17
#622 - vesa / @XingfDu

01/08/2021 at 08:37AM

17
#623 - 王軒 / @XMRHR

01/16/2021 at 01:34AM

17
#624 - pete / @pedrbrun

01/22/2021 at 02:21AM

17
#625 - Nathan Sharp / @NazzaSharp

01/24/2021 at 05:14PM

18
#626 - Maibritt Illner / @Maibritt_Illner

08/04/2020 at 05:54PM

18
#627 - zaru / @zaru

08/18/2020 at 04:46AM

18
#628 - Nathan Hollows / @nathanhollows

08/20/2020 at 10:45PM

18
#629 - victor devyatov / @DevyatovVictor

09/01/2020 at 08:54PM

18
#630 - dadams2 / @dadams217

10/30/2020 at 01:51PM