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 5666943bac55c907fd02066f

comments galore

Basic comment reformatting

Start file
/*
 * comments
 * yay comments
 * so informative, the information is really yes
 * wowowowowow
 * mind blown
 * and that's how the allocator works
 */
End file
// comments
// yay comments
// so informative, the information is really yes
// wowowowowow
// mind blown
// and that's how the allocator works

View Diff

1,8c1,6
< /*
<  * comments
<  * yay comments
<  * so informative, the information is really yes
<  * wowowowowow
<  * mind blown
<  * and that's how the allocator works
<  */
---
> // comments
> // yay comments
> // so informative, the information is really yes
> // wowowowowow
> // mind blown
> // and that's how the allocator works

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 366 remaining solutions by signing in and submitting your own entry
#367 Jay Hack / @_jayhack_ - Score: 68 - 12/18/15 @ 04:14
dd7ggdd:%i<BS>A<BS>I//<BS><BS><BS><BS>%s/*<BS>\*//<BS>\/\/<CR><Up><Up><Up><Up><Up><BS>x<Down>xjxjxjxjxjkkkkkjjjjjj:wq<CR>

0 comments


Created by: @tedsta0

367 active golfers, 849 entries

Leaderboard (lowest score wins):
10
#181 - Arijus / @argshook

06/16/2016 at 01:05PM

10
#182 - TaoChen / @632143592Tao

06/17/2016 at 07:53AM

10
#183 - Ameen P / @Ameen_P1

06/18/2016 at 11:34PM

10
#184 - Vaisian / @Vaisian

07/06/2016 at 05:42PM

10
#185 - tgmeng / @lazy_fabric

07/11/2016 at 11:24AM

10
#186 - 王运 / @640138017

07/18/2016 at 05:49AM

10
#187 - André Peric Tavares / @AndrePeric

07/20/2016 at 11:15PM

10
#188 - Alonzo / @tolver_a

07/22/2016 at 10:54PM

10
#189 - Jeremiah Goyette / @JeremiahGoyette

08/01/2016 at 03:00AM

10
#190 - George Angelopoulos / @g_usermod

08/05/2016 at 08:56AM

10
#191 - Herbert S. / @herbertshlong

08/05/2016 at 10:59PM

10
#192 - Will / @obiwan__k3n00bi

08/14/2016 at 10:23PM

10
#193 - Antoni Villalonga / @friki

08/15/2016 at 05:49PM

10
#194 - Martin Tõnusoo / @martintonusoo

08/27/2016 at 08:39PM

10
#195 - jdupont655 / @jdupont655

09/02/2016 at 01:25AM

10
#196 - Stephen Aument / @saument

09/02/2016 at 06:19PM

10
#197 - Utkrisht Dhankar / @UtkrishtDhankar

09/08/2016 at 05:09AM

10
#198 - hor1ace / @hor3ace

09/08/2016 at 08:24AM

10
#199 - loki2441 / @loki2441

09/10/2016 at 05:30AM

10
#200 - Constantine / @ConstantineHatz

09/20/2016 at 10:51PM

10
#201 - Nico / @_Nico_Caro

09/27/2016 at 04:23PM

10
#202 - Netrisk Cool / @C00lt0

10/01/2016 at 09:47AM

10
#203 - TweetDreams / @TweetMusicians

10/08/2016 at 11:57PM

10
#204 - trx / @trxdbg

10/11/2016 at 10:19AM

10
#205 - Christian Rondeau / @c_rondeau

10/17/2016 at 11:51AM

10
#206 - Bill Ruddock / @biinari

10/25/2016 at 01:38PM

10
#207 - John Barbero Unenge / @JBarberU

11/18/2016 at 01:33PM

10
#208 - Etienne Florent / @EtienneFlorent

11/23/2016 at 04:35PM

10
#209 - Jon Louie / @jjisnow

11/24/2016 at 03:00AM

10
#210 - Wessel Sinnema / @wsinnema

11/27/2016 at 04:59PM