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 60340000c06738000924d803

Inverting Lines

A simple challenge to invert all lines, except the first.

Start file
Here’s the thing about Vim.
Ex mode too, and it’s magic! 
Ex commands, there be dragons!
Until you realize it can help you be more efficient.
Learning about regexes sounds boring,
End file
Here’s the thing about Vim.
Learning about regexes sounds boring,
Until you realize it can help you be more efficient.
Ex commands, there be dragons!
Ex mode too, and it’s magic! 

View Diff

2,4d1
< Ex mode too, and it’s magic! 
< Ex commands, there be dragons!
< Until you realize it can help you be more efficient.
5a3,5
> Until you realize it can help you be more efficient.
> Ex commands, there be dragons!
> Ex mode too, and it’s magic! 

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 521 remaining solutions by signing in and submitting your own entry
#522 nagomin25 / @nagomin25 - Score: 95 - 09/15/25 @ 02:21
jjjjjddkki<CR><Up><Esc>p<Up>dd<Down><Down><Down>dd<Up>pdd<Up><Up><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right><Right>o<Esc>p<Up>dd<Down><Down>dd<Up>o<Esc>p<Up>dd<Esc>:wq<CR>

0 comments


Created by: @iviarcio

522 active golfers, 1952 entries

Leaderboard (lowest score wins):
12
#301 - x03n046 / @x03n046

05/13/2022 at 12:48AM

12
#302 - Irakli Chigvaria / @tchigvaria

05/28/2022 at 07:27AM

12
#303 - Siddharth Murali / @SidTweetsALess

07/12/2022 at 06:32AM

12
#304 - Sarang Khim / @sarang_khim

07/27/2022 at 08:32AM

12
#305 - brett / @brettyukich

07/27/2022 at 12:18PM

12
#306 - SH / @SH37248866

09/21/2022 at 07:31PM

12
#307 - snowy / @snowyeveryday

10/28/2022 at 02:33AM

12
#308 - makita0x01 / @Makita81234049

02/14/2023 at 07:50AM

12
#309 - Garlic Bread / @GarlicB30592807

03/04/2023 at 10:04PM

12
#310 - くりち / 栗原佑弥 / @kurichi97

07/04/2023 at 06:09AM

12
#311 - Monkey Boy / @monkey29089

09/24/2023 at 05:45AM

12
#312 - Abdelrahman Madkour / @A3Madkour

11/23/2023 at 05:56PM

12
#313 - Meya / @meya-zhao

03/15/2024 at 02:49AM

12
#314 - gpfl0712 / @gpfl0712

04/13/2024 at 08:15PM

12
#315 - luke37842 / @luke37842

05/14/2024 at 03:44PM

12
#316 - Giacomo Sansone / @pcineverdies

07/05/2024 at 07:37PM

13
#317 - せいほう / @FICSQF

02/22/2021 at 09:56PM

13
#318 - chocolate / @chocola81394123

02/23/2021 at 05:56AM

13
#319 - Madelyn Freed / @demonaday

02/23/2021 at 03:53PM

13
#320 - Xzavie / @Xzavie3

02/25/2021 at 03:57AM

13
#321 - samuel wang / @phyguan

02/26/2021 at 03:42AM

13
#322 - Tarek Fadali / @FadaliTarek

03/03/2021 at 09:31PM

13
#323 - Julius Marozas / @JuliusMarozas

03/05/2021 at 10:44PM

13
#324 - Mattias Fransson / @azzidoos

03/09/2021 at 08:53AM

13
#325 - Danny Sanchez / @Dane1410s

03/10/2021 at 02:46AM

13
#326 - Kaustubh Murumkar / @k_austub_h

03/10/2021 at 02:21PM

13
#327 - Robert Verst / @r_verst

03/15/2021 at 12:56PM

13
#328 - Azeddine Hamdaoui / @Azeddine_Hmd

03/16/2021 at 03:39AM

13
#329 - asdgfwaefewf123123 / @asdgfwaefewf121

03/17/2021 at 12:26PM

13
#330 - Thanh-Nhan Nguyen / @ThanhNh17788701

05/12/2021 at 02:06AM