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 50d0d80eaa503f000200001b

Swap assigned value

Simple problem but looking for interesting solutions.

Start file
app.config['CHALLENGE_FOLDER'] = SOLUTIONS_FOLDER
app.config['SOLUTIONS_FOLDER'] = CHALLENGE_FOLDER
End file
app.config['CHALLENGE_FOLDER'] = CHALLENGE_FOLDER
app.config['SOLUTIONS_FOLDER'] = SOLUTIONS_FOLDER

View Diff

diff --git 1/tmp/vimgolf_problem.in 2/tmp/vimgolf_problem.out
index 686e836..225e001 100644
--- 1/tmp/vimgolf_problem.in
+++ 2/tmp/vimgolf_problem.out
@@ -1,2 +1,2 @@
-app.config['CHALLENGE_FOLDER'] = SOLUTIONS_FOLDER
-app.config['SOLUTIONS_FOLDER'] = CHALLENGE_FOLDER
+app.config['CHALLENGE_FOLDER'] = CHALLENGE_FOLDER
+app.config['SOLUTIONS_FOLDER'] = SOLUTIONS_FOLDER

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 225 remaining solutions by signing in and submitting your own entry
#226 hasiotis / @hasiotis - Score: 101 - 04/16/13 @ 20:56
:%s/=\(\)<Left><Left><Left><Left> <Right><Right>.*<Right><Right>\n<BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><BS>:<Tab>%s/\(.*\) = \(.*\)\n\(.*\) = \(.*\)/\1 = \4\r\3 = \2/<CR>:<Up><Home><Del><CR>:wq<CR>

0 comments


Created by: @ThePrafulMathur

226 active golfers, 525 entries

Leaderboard (lowest score wins):
10
#61 - D / @justcallmedrago

02/23/2014 at 02:52AM

10
#62 - Thomas GUILLORY / @thomasguillory

02/28/2014 at 01:18PM

10
#63 - Marchand Paul-Valère / @pvmarch

02/28/2014 at 01:18PM

10
#64 - vimgolf copycat / @vimgolf_copycat

03/08/2014 at 06:23PM

10
#65 - John Braxler / @braxler

04/02/2014 at 06:18PM

10
#66 - ZorgroZ / @ZorgroZ

04/12/2014 at 04:02PM

10
#67 - lastsseldon / @lastsseldon

05/11/2014 at 09:08PM

10
#68 - John Meisner / @jmeisned

06/27/2014 at 05:26PM

10
#69 - Joey Twiddle / @joeytwiddle

07/19/2014 at 07:00PM

10
#70 - Eric Kever / @codeoverlode

09/30/2014 at 05:49PM

10
#71 - eBrnd / @eBrnd

11/05/2014 at 09:13PM

10
#72 - kimber gonzalez / @kimberlycreates

02/06/2015 at 07:55PM

10
#73 - mark0829 / @mark0829

03/05/2015 at 01:29AM

10
#74 - TheProgrammer971 / @tp971

03/14/2015 at 03:45PM

10
#75 - Adrien Fabre / @statox42

05/14/2015 at 05:30PM

10
#76 - Evan Coleman / @edc1591

06/19/2015 at 08:58PM

10
#77 - Ásgeir Bjarnason / @abjarnasn

07/25/2015 at 10:30PM

10
#78 - Dan Moldovan / @Lenea92

08/31/2015 at 11:05AM

10
#79 - Kevin Merlin / @mp3merlin

09/17/2015 at 12:14PM

10
#80 - Walker Boh / @walker_boh

10/14/2015 at 08:14AM

10
#81 - Jon Krause / @jkrause314

12/19/2015 at 01:12AM

10
#82 - tgmeng / @lazy_fabric

06/14/2016 at 09:36AM

10
#83 - Will / @obiwan__k3n00bi

09/03/2016 at 07:24AM

10
#84 - Daniel / @Daniel00288663

03/31/2017 at 02:09PM

10
#85 - Gurukandhamoorthi / @Gurukandhamoor1

07/16/2017 at 04:11PM

10
#86 - Turkey Man / @lvturkeyman

11/25/2017 at 08:45AM

10
#87 - BarbaJol / @drpproteus

01/09/2018 at 05:46PM

10
#88 - Arijus / @argshook

03/22/2018 at 01:05PM

10
#89 - DHM / @DHM29978992

04/30/2018 at 07:16PM

10
#90 - Evgeny`s Kindle / @EvgenyKindle

05/01/2018 at 06:37PM