Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Leaderboard, Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put 4fca29ddd3a0d40001000038

Remove semicolons after expressions

A follow-up for http://vimgolf.com/challenges/4fc9d767d3a0d4000100000e.

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 131 remaining solutions by signing in and submitting your own entry
#132 curist / @curist - Score: 8 - 07/09/13 @ 07:46
:%s/;<CR>ZZ

0 comments

#133 Nathan / @NathanHarperoni - Score: 8 - 08/08/13 @ 14:15
:%s/;<CR>ZZ

0 comments

#134 cj / @cj01101 - Score: 8 - 08/16/13 @ 22:07
:%s/;<CR>ZZ

0 comments

#135 Oliver Christ / @0liverChrist - Score: 8 - 09/27/13 @ 22:43
:%s/;<CR>ZZ

0 comments

#136 foo / @foo88832727 - Score: 8 - 10/18/13 @ 21:32
:%s/;<CR>ZZ

0 comments

#137 Casey Dwyer / @caseydwyer - Score: 8 - 11/04/13 @ 21:44
Q%s/;<CR>x<CR>

0 comments

#138 US Dollar Price / @USDollarPrice - Score: 8 - 11/04/13 @ 22:15
:%s/;<CR>ZZ

0 comments

#139 Stefan Schmidt / @stafue - Score: 8 - 12/06/13 @ 15:26
:%s/;<CR>ZZ

0 comments

#140 Quota / @Quotad - Score: 8 - 02/10/14 @ 15:50
:%s/;<CR>ZZ

0 comments

#141 jimauthors / @jimauthors - Score: 8 - 03/04/14 @ 00:48
:%s/;<CR>ZZ

0 comments

#142 Mark Inksa / @MInksaCS - Score: 8 - 05/11/14 @ 12:32
:%s/;<CR>ZZ

0 comments

#143 Ram Tamtam / @ramtamtamtam - Score: 8 - 06/30/14 @ 14:36
:%s/;<CR>ZZ

0 comments

#144 Tj / @yrddy - Score: 8 - 08/19/14 @ 11:37
:%s/;<CR>ZZ

0 comments

#145 mark0829 / @mark0829 - Score: 8 - 03/19/15 @ 05:27
:%s/;<CR>ZZ

0 comments

#146 Alec Chen / @alec929 - Score: 9 - 11/03/12 @ 14:12
:%s/;/<CR>ZZ

0 comments

#147 RobertT / @techrt2050 - Score: 9 - 07/10/13 @ 08:59
:%s/.$<CR>ZZ

0 comments

#148 Hachez Floran / @FloranHachez - Score: 9 - 09/06/13 @ 23:14
<CR>:%s/;<CR>ZZ

0 comments

#149 James Cash / @jamesnvc - Score: 10 - 06/02/12 @ 16:52
:%s/;//<CR>ZZ

0 comments

#150 Drew Benedetti / @cnorsl - Score: 10 - 07/17/12 @ 19:28
:%s/;//<CR>ZZ

0 comments

#151 Christopher Brew / @Seph1rothVII - Score: 10 - 07/24/12 @ 21:16
:%s/;//<CR>ZZ

0 comments

#152 it's not me / @dpree - Score: 10 - 08/10/12 @ 15:47
:g/;/s/<CR>ZZ

0 comments

#153 Tyler Breisacher / @tbreisacher - Score: 10 - 08/25/12 @ 07:42
:%s/;//<CR>ZZ

0 comments

#154 Alex Hammel / @AlexJHammel - Score: 10 - 12/23/12 @ 18:22
:%s/;//<CR>ZZ

0 comments

#155 Asmund Liseth / @Asmund_L - Score: 10 - 01/12/13 @ 17:34
:%s/;//<CR>ZZ

0 comments

#156 Marcelo Izaguirre / @shinigamichelo - Score: 10 - 05/30/14 @ 11:10
:,$s/;$<CR>ZZ

0 comments

#157 Raphaël De Giusti / @raphdg - Score: 11 - 06/02/12 @ 18:42
$*xnxnxnxZZ

0 comments

#158 olopost / @olopost - Score: 11 - 08/19/14 @ 20:18
:%s/;//g<CR>ZZ

0 comments

#159 lauri lehmijoki / @laurilehmijoki - Score: 12 - 06/02/12 @ 14:58
qa$xjjq3@aZZ

@laurilehmijoki: There is a drawback to this solution: it forces me to take into account the amount of semicolons I want to remove.

@wondible: There's always the recursive macro qa...@aq@a Though it might get a little crazy if the register isn't empty beforehand.

2 comments

#160 NuM / @NuM314 - Score: 12 - 10/05/13 @ 23:43
4@='$xjj'<CR>ZZ

0 comments

#161 Tomasz Wesołowski / @KosGD - Score: 12 - 10/13/14 @ 11:40
qq$x2jq3@qZZ

0 comments

#162 Rohin Patel / @ropatel - Score: 14 - 11/02/12 @ 00:49
:%s/;//g<CR>:wq!<CR>

0 comments

#163 Noel Alejandro / @noelrock333 - Score: 15 - 06/23/12 @ 00:03
:%s/;//<CR>:w<CR><Esc>:q<CR>

0 comments

#164 Samuel Masuy / @samasuy - Score: 15 - 07/24/14 @ 16:06
qaI<Esc>A<BS><Esc>jjq3@aZZ

0 comments

Created by: @laurilehmijoki

164 active golfers, 345 entries

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

06/02/2012 at 04:39PM

6
#2 - Tim Chase / @gumnos

06/02/2012 at 04:48PM

6
#3 - Alain Gilbert / @alain_gilbert

06/02/2012 at 05:16PM

6
#4 - Sebastian Kusnier / @skusnier

06/02/2012 at 06:25PM

6
#5 - Federico Galassi / @federicogalassi

06/02/2012 at 08:44PM

6
#6 - h_east (DDD ready) / @h_east

06/03/2012 at 01:48AM

6
#7 - akhilravidas / @akhilravidas

06/03/2012 at 10:25AM

6
#8 - Rod Knowlton / @codelahoma

06/03/2012 at 06:11PM

6
#9 - Sergey / @sav86

06/04/2012 at 12:19AM

6
#10 - Benson Kim / @BensonRLA

06/05/2012 at 03:29PM

6
#11 - Benoit Mortgat / @Benoit_Mortgat

06/05/2012 at 06:50PM

6
#12 - Paul Gessler / @pdgessler

06/07/2012 at 04:38AM

6
#13 - Kerson Hsiao / @KersonHsiao

06/07/2012 at 10:52AM

6
#14 - Dave / @zzdave13

06/07/2012 at 08:41PM

6
#15 - utopiah / @utopiah

06/08/2012 at 01:04PM

6
#16 - Drew Hannay / @drewhannay

06/09/2012 at 07:07AM

6
#17 - Joakim L. Engeset / @joakim_eng

06/11/2012 at 05:35PM

6
#18 - Rolf Bjaanes / @rolfb

06/15/2012 at 02:08PM

6
#19 - noom narze / @NarzE

06/18/2012 at 06:16AM

6
#20 - Ryan O'Connell / @Salshammath

06/21/2012 at 12:58AM

6
#21 - Greg Sabo / @gregsabo

06/21/2012 at 04:25AM

6
#22 - Ilya Ermolin / @ermolinis

06/21/2012 at 03:41PM

6
#23 - mwatkward / @AftrschoolSpe

06/22/2012 at 12:01PM

6
#24 - abernardes / @abernardes

06/22/2012 at 03:40PM

6
#25 - Ryan Kois / @r_kois

06/23/2012 at 06:11PM

6
#26 - Raúl Jara / @rauljara

07/06/2012 at 08:56PM

6
#27 - Sebastian Korten / @FlashKorten

07/15/2012 at 03:32PM

6
#28 - Dr. Funkenstein / @_weslly

07/16/2012 at 04:20PM

6
#29 - Oliver Mader / @dotb52

07/17/2012 at 07:10AM

6
#30 - Ben Alpert / @soprano

07/17/2012 at 09:07AM

6
#31 - Benoit Thiell / @benoitthiell

07/20/2012 at 01:35PM

6
#32 - Jordan Eldredge / @captbaritone

07/29/2012 at 03:48PM

6
#33 - Ryan Patterson / @CGamesPlay

07/29/2012 at 09:42PM

6
#34 - Greg Sexton / @greg_sexton

08/05/2012 at 10:17AM

6
#35 - Jaime A. Sánchez / @jashbeta

08/10/2012 at 08:13PM

6
#36 - Sean Griffin / @sgrif

08/13/2012 at 02:44AM

6
#37 - Reed Riley / @ReedRile

08/13/2012 at 06:35PM

6
#38 -  Ikhsan Maulana / @ixandidu

08/18/2012 at 03:12PM

6
#39 - ElasticSwarts / @EmileSwarts

08/19/2012 at 12:40PM

6
#40 - Joseph Reddington / @joereddington

08/20/2012 at 10:39AM

6
#41 - Arto Vuori / @dhpe

08/31/2012 at 07:28PM

6
#42 - Joseph J. Piché / @jjpiche

09/02/2012 at 04:15PM

6
#43 - Conner McDaniel / @connermcd

09/18/2012 at 04:32AM

6
#44 - Victor Ramirez / @virako

10/01/2012 at 01:09PM

6
#45 - Vim rocks / @vimrocks

10/07/2012 at 07:30PM

6
#46 - Dan Goldstein / @dggoldst

10/15/2012 at 08:31PM

6
#47 - Adelar S. Queiróz / @adelarsq

11/30/2012 at 12:42AM

6
#48 - Yann Moisan / @YannMoisan

01/05/2013 at 01:06PM

6
#49 - Daniel Hahler / @blueyed

01/22/2013 at 08:38PM

6
#50 - Steve Tjoa / @stevetjoa

02/08/2013 at 08:23PM

6
#51 - jared miller / @jared_vim

03/03/2013 at 12:14AM

6
#52 - Joel Elkins / @dice_tea

03/05/2013 at 06:24AM

6
#53 - Trevor Powell / @DoomedBunnies

03/20/2013 at 01:36AM

6
#54 - Global Maquereau / @GlobalMaquereau

04/24/2013 at 03:13PM

6
#55 - Al Stanforth / @AlStanforth

05/01/2013 at 03:37PM

6
#56 - sweet.mike.vg / @SweetMikeVg

05/02/2013 at 12:47AM

6
#57 - Justin / @justinjaffray

05/02/2013 at 01:54AM

6
#58 - Marco Hinz / @_mhinz_

05/23/2013 at 03:33PM

6
#59 - Tom User / @kiryph

05/30/2013 at 05:25PM

6
#60 - M8R eonxi21 / @eonxi21

06/01/2013 at 11:39PM

6
#61 - Petro Тrouq / @zulolosi

06/05/2013 at 06:18AM

6
#62 - Shoop Da Whoop / @ShoopDaWhoop8

06/06/2013 at 08:41PM

6
#63 - Bradd Szonye / @bszonye

07/13/2013 at 01:48PM

6
#64 - moo goo / @m00g000

07/19/2013 at 02:32PM

6
#65 - James / @Dronak

08/29/2013 at 10:45PM

6
#66 - isayoldchap / @isayoldchap

09/20/2013 at 05:09AM

6
#67 - hiding / @I_haveno_name

10/01/2013 at 07:28AM

6
#68 - Charles H. Leggett / @cleggett

11/05/2013 at 02:56AM

6
#69 - raymangum / @raymangum

12/27/2013 at 06:14PM

6
#70 - Xelrifos / @Xelrifos

02/18/2014 at 08:05PM

6
#71 - Joonas Pihlajamaa / @jokkebk

03/19/2014 at 11:17AM

6
#72 - John Braxler / @braxler

04/17/2014 at 12:51PM

6
#73 - Felipe Jaramillo F / @mrfelipe

05/01/2014 at 04:44AM

6
#74 - Peeby Thirtyone / @peeby31

05/05/2014 at 08:32PM

6
#75 - Caek / @Caek_

07/25/2014 at 03:28AM

6
#76 - Leeren / @Leeren

08/09/2014 at 10:03PM

6
#77 - bratliff / @bratliff

08/10/2014 at 07:22AM

8
#78 - Justin Love / @wondible

06/02/2012 at 03:38PM

8
#79 - Asenar / @asenar

06/02/2012 at 03:51PM

8
#80 - Pawel Obrok / @mrYapee

06/02/2012 at 03:54PM

8
#81 - Thomas Schönwälder / @Masei1988

06/02/2012 at 05:21PM

8
#82 - 無ん垢の叫び / @john_ababa

06/02/2012 at 06:34PM

8
#83 - Jonathan Lozinski / @jlozinski

06/02/2012 at 07:16PM

8
#84 - John Whitley / @johnwhitley

06/03/2012 at 01:41AM

8
#85 - Jacob Vosmaer / @jacobvosmaer

06/03/2012 at 11:25AM

8
#86 - Mattiassich Ákos / @mattiassicha

06/03/2012 at 06:06PM

8
#87 - mnx / @mnxx

06/03/2012 at 10:08PM

8
#88 - Simon Nicolussi / @sinic

06/04/2012 at 06:59PM

8
#89 - Javier Blanco / @jbgutierrez

06/04/2012 at 10:39PM

8
#90 - Benjamin Sergeant / @bsergean

06/05/2012 at 04:43AM

8
#91 - captain_morgan / @captain_morgan

06/05/2012 at 09:19AM

8
#92 - Roel van Dijk / @rdvdijk

06/05/2012 at 03:42PM

8
#93 - shutl_test / @shutl_test

06/06/2012 at 11:19AM

8
#94 - Robin Landström / @R_Landstrom

06/06/2012 at 05:24PM

8
#95 - Matty Williams / @matty_jwilliams

06/08/2012 at 02:52PM

8
#96 - Josh Steiner / @josh_steiner

06/12/2012 at 07:53PM

8
#97 - Carlos Hernando / @chernando

06/13/2012 at 06:57PM

8
#98 - J Paul Daigle / @jpauldaigle

06/18/2012 at 09:02PM

8
#99 - Batata / @hetalbatata

06/20/2012 at 01:01AM

8
#100 - Vitaly Kushner / @vkushner

06/21/2012 at 01:13AM

8
#101 - exitmouse / @exitmouse

06/22/2012 at 05:40PM

8
#102 - Brandon Montgomery / @bmonty

06/23/2012 at 01:50PM

8
#103 - Vasil Sakarov / @vsakarov

06/26/2012 at 09:57AM

8
#104 - Philippe Creux / @pcreux

07/13/2012 at 06:54AM

8
#105 - Eric Mathison / @ericmathison

07/13/2012 at 09:36AM

8
#106 - Verity / @dv4me

07/15/2012 at 12:54AM

8
#107 - Lukas Korsika / @LKorsika

07/17/2012 at 06:09AM

8
#108 - William Dunand / @wdunand

07/27/2012 at 06:00AM

8
#109 - Chris Brown / @engineercyb

07/31/2012 at 08:47PM

8
#110 - Björn Holdt / @bholdt

08/09/2012 at 05:33PM

8
#111 - Michael Limiero / @michaellimiero

08/14/2012 at 11:16PM

8
#112 - Benjo Batumbakal / @benjobatumbakal

08/23/2012 at 11:59AM

8
#113 - vansan / @VinceVansan

08/23/2012 at 06:03PM

8
#114 - Maksim S. / @waynesayonara

09/02/2012 at 01:42PM

8
#115 - Arne Ehrlich / @typedlambda

09/06/2012 at 06:50AM

8
#116 - jakeroberts / @jakeroberts

09/07/2012 at 06:56AM

8
#117 - Federico Bond / @federicobond

09/22/2012 at 11:53PM

8
#118 - Sven Koesling / @McSvenster

09/24/2012 at 07:24AM

8
#119 - Javier Cervantes / @solojavier

10/08/2012 at 10:04PM

8
#120 - Édouard M'tou / @DouardM

10/09/2012 at 06:45PM

8
#121 - Underhill Labs / @underhilllabs

11/03/2012 at 03:41AM

8
#122 - Saxon Unrue / @joeunrue

11/09/2012 at 01:24PM

8
#123 - Kenneth Waters / @gen_witt

11/13/2012 at 09:08PM

8
#124 - Michael / @patheticpat

12/17/2012 at 02:03PM

8
#125 - Zarak / @z0k

12/19/2012 at 03:22PM

8
#126 - Pedro Franceschi / @pedroh96

02/06/2013 at 02:40AM

8
#127 - Addisu Taddese / @azeey

03/02/2013 at 07:10PM

8
#128 - Tyler / @tylerbindon

04/03/2013 at 07:46PM

8
#129 - Aaron Josephs / @aaronjosephs1

05/02/2013 at 02:57AM

8
#130 - Anh Do / @quanganhdo

06/04/2013 at 05:16AM

8
#131 - Michael Kummer / @randompast

07/06/2013 at 08:14PM

8
#132 - curist / @curist

07/09/2013 at 07:46AM

8
#133 - Nathan / @NathanHarperoni

08/08/2013 at 02:15PM

8
#134 - cj / @cj01101

08/16/2013 at 10:07PM

8
#135 - Oliver Christ / @0liverChrist

09/27/2013 at 10:43PM

8
#136 - foo / @foo88832727

10/18/2013 at 09:32PM

8
#137 - Casey Dwyer / @caseydwyer

11/04/2013 at 09:44PM

8
#138 - US Dollar Price / @USDollarPrice

11/04/2013 at 10:15PM

8
#139 - Stefan Schmidt / @stafue

12/06/2013 at 03:26PM

8
#140 - Quota / @Quotad

02/10/2014 at 03:50PM

8
#141 - jimauthors / @jimauthors

03/04/2014 at 12:48AM

8
#142 - Mark Inksa / @MInksaCS

05/11/2014 at 12:32PM

8
#143 - Ram Tamtam / @ramtamtamtam

06/30/2014 at 02:36PM

8
#144 - Tj / @yrddy

08/19/2014 at 11:37AM

8
#145 - mark0829 / @mark0829

03/19/2015 at 05:27AM

9
#146 - Alec Chen / @alec929

11/03/2012 at 02:12PM

9
#147 - RobertT / @techrt2050

07/10/2013 at 08:59AM

9
#148 - Hachez Floran / @FloranHachez

09/06/2013 at 11:14PM

10
#149 - James Cash / @jamesnvc

06/02/2012 at 04:52PM

10
#150 - Drew Benedetti / @cnorsl

07/17/2012 at 07:28PM

10
#151 - Christopher Brew / @Seph1rothVII

07/24/2012 at 09:16PM

10
#152 - it's not me / @dpree

08/10/2012 at 03:47PM

10
#153 - Tyler Breisacher / @tbreisacher

08/25/2012 at 07:42AM

10
#154 - Alex Hammel / @AlexJHammel

12/23/2012 at 06:22PM

10
#155 - Asmund Liseth / @Asmund_L

01/12/2013 at 05:34PM

10
#156 - Marcelo Izaguirre / @shinigamichelo

05/30/2014 at 11:10AM

11
#157 - Raphaël De Giusti / @raphdg

06/02/2012 at 06:42PM

11
#158 - olopost / @olopost

08/19/2014 at 08:18PM

12
#159 - lauri lehmijoki / @laurilehmijoki

06/02/2012 at 02:58PM

12
#160 - NuM / @NuM314

10/05/2013 at 11:43PM

12
#161 - Tomasz Wesołowski / @KosGD

10/13/2014 at 11:40AM

14
#162 - Rohin Patel / @ropatel

11/02/2012 at 12:49AM

15
#163 - Noel Alejandro / @noelrock333

06/23/2012 at 12:03AM

15
#164 - Samuel Masuy / @samasuy

07/24/2014 at 04:06PM