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

Append semicolon after expressions

Some lines need the semicolon, some don't.

Start file
var foo

var bar = myCoolStuff()

callRemote()

foo = callTheWorld()
End file
var foo;

var bar = myCoolStuff();

callRemote();

foo = callTheWorld();

View Diff

1c1
< var foo
---
> var foo;
3c3
< var bar = myCoolStuff()
---
> var bar = myCoolStuff();
5c5
< callRemote()
---
> callRemote();
7c7
< foo = callTheWorld()
---
> foo = callTheWorld();

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 369 remaining solutions by signing in and submitting your own entry
#370 Noel Alejandro / @noelrock333 - Score: 38 - 06/23/12 @ 00:08
:4<BS>%s.<BS>/s<BS>)/x<BS>no<BS><BS>/<BS>(<BS>);/<CR>1G7la;<Esc>:w<CR><C-W>q

0 comments


Created by: @laurilehmijoki

370 active golfers, 898 entries

Leaderboard (lowest score wins):
11
#91 - merphant / @merphant

10/24/2015 at 08:03AM

11
#92 - Mister Knister / @vimgolf_ctrl_x

03/04/2016 at 01:43PM

11
#93 - ramandeep randhawa / @rsrandhawa

04/11/2016 at 02:02AM

11
#94 - tPenguinLTG / @tpenguinltg

05/01/2016 at 08:54PM

11
#95 - Ikypiky / @nerdbeereis

06/16/2016 at 08:12AM

11
#96 - Leix b / @leix_b

07/08/2016 at 04:39PM

11
#97 - Jeremiah Goyette / @JeremiahGoyette

08/04/2016 at 12:43AM

11
#98 - Will / @obiwan__k3n00bi

08/23/2016 at 12:39AM

11
#99 - jj johnson / @jcassj1

08/23/2016 at 10:29AM

11
#100 - Mike Land / @mikepland

08/24/2016 at 12:27AM

11
#101 - Tom McHenry / @tommchenry

08/24/2016 at 12:28AM

11
#102 - Caroline / @carokenworthy

08/24/2016 at 12:28AM

11
#103 - Christopher Erin / @MCNormalMode

01/18/2017 at 01:11AM

11
#104 - Saki Gw / @Sakigw

01/26/2017 at 02:33AM

11
#105 - Jim Bob / @babyclubber

02/28/2017 at 11:23PM

11
#106 - Cougar / @__Cougar__

03/11/2017 at 09:23PM

11
#107 - Daniel / @Daniel00288663

03/30/2017 at 02:45PM

11
#108 - Akash Khan / @akash93

04/21/2017 at 06:16AM

11
#109 - Remus Dalrymple / @bornintheflames

05/08/2017 at 02:42AM

11
#110 - Chicuella / @chicuellahere

05/12/2017 at 03:08PM

11
#111 - Wang Wu / @rubepeg

05/13/2017 at 07:09AM

11
#112 - Turkey Man / @lvturkeyman

11/23/2017 at 08:13AM

11
#113 - BarbaJol / @drpproteus

01/08/2018 at 06:42PM

11
#114 - DHM / @DHM29978992

04/30/2018 at 01:19AM

11
#115 - Marius Lucian Pop / @mlpinit

07/25/2018 at 12:31AM

11
#116 - Dax / @zacoxi

12/05/2018 at 06:00AM

11
#117 - alekfed / @alek_fed

04/16/2019 at 12:02PM

11
#118 - majo senf / @majo_senf

06/21/2019 at 03:36PM

11
#119 - Himavanth Reddy / @Himavanth1909

08/12/2019 at 09:54AM

11
#120 - Wistan Chou / @wisty97

08/21/2019 at 09:05PM