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 5287aac7bba8eb0002000002

Permutations N=4

Could use backtracking or other algorithm to generate sorted numbers. Second chance !

Start file
1234
End file
1234
1243
1324
1342
1423
1432
2134
2143
2314
2341
2413
2431
3124
3142
3214
3241
3412
3421
4123
4132
4213
4231
4312
4321

View Diff

1a2,24
> 1243
> 1324
> 1342
> 1423
> 1432
> 2134
> 2143
> 2314
> 2341
> 2413
> 2431
> 3124
> 3142
> 3214
> 3241
> 3412
> 3421
> 4123
> 4132
> 4213
> 4231
> 4312
> 4321

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 18 remaining solutions by signing in and submitting your own entry
#19 Tyler / @tylerbindon - Score: 82 - 11/17/13 @ 03:34
YP$xPyjPl<C-V>jxpyjP$<C-V>jxPVGYPl<C-V>5j$:s/2/1<CR><C-V>{r2Pl<C-V>5j$:s/3/1<CR><C-V>{r3Pl<C-V>5j$:s/4/1<CR><C-V>{r4:sor|x<CR>

0 comments


Created by: @zulolosi

19 active golfers, 61 entries

Leaderboard (lowest score wins):
25
#1 - Urtica dioica / @udioica

04/26/2014 at 06:17AM

25
#2 - John Braxler / @braxler

08/22/2014 at 03:10PM

25
#3 - 何晨 / @hechen0_

09/22/2016 at 05:21PM

25
#4 - Turkey Man / @lvturkeyman

12/06/2018 at 06:16AM

25
#5 - πšƒπš’πšπš˜πšžπšŠπš— πšƒπšŽπš’πšœπšœπš’πšŽπš› / @TitouanT_

02/19/2019 at 05:51PM

25
#6 - Peppa Pig / @PeppaPi95550250

06/26/2024 at 09:30AM

27
#7 - Kerson Hsiao / @KersonHsiao

02/25/2014 at 05:24AM

27
#8 - MP / @Enemy_m

02/26/2014 at 01:19AM

27
#9 - Petro Π’rouq / @zulolosi

03/10/2014 at 12:43AM

27
#10 - i1464083 / @i1464083

11/18/2016 at 10:59AM

33
#11 - Jon Krause / @jkrause314

04/12/2016 at 08:54PM

35
#12 - Ilya Ermolin / @ermolinis

11/18/2013 at 09:28AM

37
#13 - Carlos A HenrΓ­quez Q / @lagunex

02/28/2015 at 10:03PM

40
#14 - RockerZZY / @rocker_zzy

06/05/2020 at 04:57PM

45
#15 - MiΕ‚osz Łakomy / @foobar01123

01/06/2020 at 02:28AM

50
#16 - γ¨γ“γ‚γŸγ‚“ / @tokoro10g

12/02/2017 at 01:08PM

53
#17 - thasso / @thasso23

11/16/2013 at 11:01PM

53
#18 - cj / @cj01101

02/05/2014 at 12:01AM

82
#19 - Tyler / @tylerbindon

11/17/2013 at 03:34AM