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

Interweave two blocks of text

Suppose you've got data on a list of things from multiple sources. They're all in separate chunks, so how might you create a tabular output?

Start file
one
two
three
four
five
six
seven
eight
nine
ten
1
2
3
4
5
6
7
8
9
10
End file
one     1
two    
2
three  
3
four    
4
five    
5
six    
6
seven  
7
eight  
8
nine    
9
ten    
10

View Diff

1,20c1,10
< one
< two
< three
< four
< five
< six
< seven
< eight
< nine
< ten
< 1
< 2
< 3
< 4
< 5
< 6
< 7
< 8
< 9
< 10
---
> one   1
> two   2
> three 3
> four  4
> five  5
> six   6
> seven 7
> eight 8
> nine  9
> ten   10

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 214 remaining solutions by signing in and submitting your own entry
#215 Jurica / @Jurica34581259 - Score: 47 - 12/12/18 @ 12:02
:1,10s/$/\t<CR>1Gqa10j0yw10k$p<Esc>jq9@a:g/^[1-9]/d<CR>ZZ

0 comments


Created by: @mwhooker

215 active golfers, 661 entries

Leaderboard (lowest score wins):
15
#31 - Peppa Pig / @PeppaPigSg

05/25/2024 at 09:26AM

15
#32 - nickGPT / @nickandbro

08/28/2024 at 10:47PM

15
#33 - Berel94 / @Berel94

10/14/2024 at 09:44PM

16
#34 - Trevor Powell / @DoomedBunnies

12/07/2011 at 04:20AM

16
#35 - Jakub Arnold / @darthdeus

12/19/2011 at 03:43PM

16
#36 - Renat Aksitov / @Korvin79

02/08/2012 at 05:02PM

16
#37 - Federico Galassi / @federicogalassi

02/22/2012 at 09:06PM

16
#38 - John Anderson / @opejn

03/31/2012 at 04:12PM

16
#39 - Tim Chase / @gumnos

04/27/2012 at 11:18PM

16
#40 - ise0615 / @ise0615

05/05/2012 at 11:39AM

16
#41 - Sebastian Kusnier / @skusnier

05/06/2012 at 08:38PM

16
#42 - Miha Filej / @mfilej

06/26/2012 at 07:48PM

16
#43 - uoɹɹɐɥƆ ꞁǝnɯɐS / @samuelcharron

07/05/2012 at 03:51PM

16
#44 - Vim rocks / @vimrocks

10/07/2012 at 06:22PM

16
#45 - Dominick LoBraico / @pygatea

12/11/2012 at 10:57PM

16
#46 - Jared Meyering / @Jmeyering

02/25/2014 at 10:12PM

16
#47 - Antonio Jesús / @antoniojesvs

02/27/2014 at 01:03PM

16
#48 - Mark Inksa / @MInksaCS

05/10/2014 at 09:55PM

16
#49 - Francois Marais / @maraisf

09/15/2014 at 06:33PM

16
#50 - pftb12345 / @pftb12345

04/16/2015 at 01:52PM

16
#51 - Anderson Mesquita / @andersonvom

04/17/2015 at 06:41AM

16
#52 - Evan Coleman / @edc1591

05/05/2015 at 05:26PM

16
#53 - Razzi #FreePalestine / @Razzzzi

12/20/2015 at 09:03PM

16
#54 - blue fin / @blueuo

03/13/2016 at 04:16PM

16
#55 - Terje Støback / @erjets

04/14/2017 at 04:13PM

16
#56 - oops / @oopserror404

11/15/2017 at 11:16AM

16
#57 - DHM / @DHM29978992

05/03/2018 at 04:08AM

16
#58 - churaki / @churaki

01/29/2019 at 03:41PM

16
#59 - Mihai / @mihaicristiant

02/27/2019 at 02:47PM

16
#60 - vimRunnerUp3000 / @VUp3000

09/02/2019 at 05:56PM