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 556d7209f6d1a10ee6000001

swap or reverse

Try to swap or reverse the line as needed.

Start file
abcdefghijklmn
End file
abcdefghijklmn
bcdefghijklmna
cdefghijklmnba
defghijklmncba
efghijklmndcba
fghijklmnedcba
ghijklmnfedcba
hijklmngfedcba
ijklmnhgfedcba
jklmnihgfedcba
klmnjihgfedcba
lmnkjihgfedcba
mnlkjihgfedcba
nmlkjihgfedcba

View Diff

1a2,14
> bcdefghijklmna
> cdefghijklmnba
> defghijklmncba
> efghijklmndcba
> fghijklmnedcba
> ghijklmnfedcba
> hijklmngfedcba
> ijklmnhgfedcba
> jklmnihgfedcba
> klmnjihgfedcba
> lmnkjihgfedcba
> mnlkjihgfedcba
> nmlkjihgfedcba

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 67 remaining solutions by signing in and submitting your own entry
#68 Matt / @mcr05 - Score: 32 - 06/13/15 @ 09:32
qxxpqU@='Yp13@x'<CR>qq@=<C-F>-<C-X><CR>q11@qZZ

@mcr05: I wanted badly this @=<C-F> :P

1 comment


#69 Grisha Pushkov / @readoonly - Score: 32 - 06/16/15 @ 10:56
yypx$p"pylqqyypx/<C-R>p<CR>P"pylq11@qZZ

0 comments


Created by: @pftb12345

69 active golfers, 126 entries

Leaderboard (lowest score wins):
18
#61 - Adrien Fabre / @statox42

06/04/2015 at 08:45PM

18
#62 - Gerald Tilma / @GeraldTilma

10/21/2015 at 01:54AM

18
#63 - James / @Dronak

11/07/2022 at 08:41PM

19
#64 - we’re going to need a bigger bot / @assaflavie

06/09/2015 at 08:08PM

20
#65 - Gurukandhamoorthi / @Gurukandhamoor1

09/01/2017 at 03:16PM

21
#66 - Edgard Leal / @EdgardLeal

06/03/2015 at 07:37PM

24
#67 - Drew Newell / @drewnewell

06/24/2015 at 06:33PM

32
#68 - Matt / @mcr05

06/13/2015 at 09:32AM

32
#69 - Grisha Pushkov / @readoonly

06/16/2015 at 10:56AM