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 937 remaining solutions by signing in and submitting your own entry
#938 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

938 active golfers, 3797 entries

Leaderboard (lowest score wins):
9
#151 - Justin / @JustinVecchioni

01/25/2021 at 09:28PM

9
#152 - Yondonjamts Ganzorig / @yondonjamts_g

01/26/2021 at 10:18AM

9
#153 - OtterPy / @OtterPy

01/26/2021 at 02:05PM

9
#154 - Jianfeng / @Jianfen22425058

01/27/2021 at 10:28AM

9
#155 - Oleg / @Oleg36601324

01/27/2021 at 01:56PM

9
#156 - Caleb Biddulph / @BiddulphCaleb

01/27/2021 at 08:20PM

9
#157 - Gaston / @Gaston53635525

01/27/2021 at 10:50PM

9
#158 - nedlog / @nedlog18

05/18/2021 at 08:58AM

9
#159 - damned-me / @damned_me_

05/24/2021 at 04:19PM

9
#160 - Michael / @Michael62785035

05/26/2021 at 02:05PM

9
#161 - Chae Eon Lim / @ChaeEonLim1

06/13/2021 at 05:16AM

9
#162 - m397 / @m39752809546

06/18/2021 at 07:52PM

9
#163 - Sarim Aleem / @AleemSarim

06/20/2021 at 10:34PM

9
#164 - Patrick Martin / @PatrickDMartin

06/29/2021 at 08:52PM

9
#165 - lydxn / @lydxn1

07/28/2021 at 11:04PM

9
#166 - Connor / @ronnocthered

08/21/2021 at 06:35AM

9
#167 - Roman Privalov / @RomanPrivalov

08/23/2021 at 01:10AM

9
#168 - yancy / @yancy_dong

09/17/2021 at 12:48AM

9
#169 - vim_maxter / @MaxterVim

09/20/2021 at 05:43AM

10
#170 - Coded / @coded_nz

07/27/2020 at 02:24AM

10
#171 - Daniel Steinberg / @dstein64

07/27/2020 at 02:36AM

10
#172 - Smylers / @Smylers2

07/27/2020 at 05:50AM

10
#173 - Saki Gw / @Sakigw

07/27/2020 at 06:57AM

10
#174 - Jeff Cui / @jeffacce

07/27/2020 at 08:50AM

10
#175 - TimMcGuire / @mcguire

07/27/2020 at 01:47PM

10
#176 - Jan Sturm / @JanSturm77

07/27/2020 at 02:25PM

10
#177 - analogpixel / @analogp1xel

07/27/2020 at 04:42PM

10
#178 - Ángel Durán / @AngeeelD

07/28/2020 at 03:57AM

10
#179 - Petro Тrouq / @zulolosi

07/28/2020 at 11:30AM

10
#180 - Till Straube / @tillstr

07/28/2020 at 01:15PM