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 9v0060da5177000000000209

Plotting some variables in python

4 sets of (x,y) variables to plot. Just increment the numbers! Well, let's change the colors of the lines as well. Oh and we meant to plot the absolute values of course.

Start file
def Plot_All():
    plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
    plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
    plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
    plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
End file
def Plot_All():
    plt.plot(x1,abs(y1),color='k',lw=0.8,label="line #1")
    plt.plot(x2,abs(y2),color='b',lw=0.8,label="line #2")
    plt.plot(x3,abs(y3),color='r',lw=0.8,label="line #3")
    plt.plot(x4,abs(y4),color='g',lw=0.8,label="line #4")

View Diff

2,5c2,5
<     plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
<     plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
<     plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
<     plt.plot(x1,y1,color='k',lw=0.8,label="line #1")
---
>     plt.plot(x1,abs(y1),color='k',lw=0.8,label="line #1")
>     plt.plot(x2,abs(y2),color='b',lw=0.8,label="line #2")
>     plt.plot(x3,abs(y3),color='r',lw=0.8,label="line #3")
>     plt.plot(x4,abs(y4),color='g',lw=0.8,label="line #4")

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 326 remaining solutions by signing in and submitting your own entry
#327 Calarasanu Andrei / @_fanfani4_ - Score: 181 - 06/29/21 @ 09:01
jfy<C-V>4jIabs(<Esc>[1;5C<Esc>u<Esc>w)bBBkkkwwwwwwwww)(jf,f,i)<Esc>j<C-A>bbbbbbbi<BS>2)<Esc>ji<BS>3)<Esc>ji<BS>4)<Esc>bbbbkkk<C-A>bbbb<C-A>bbbb<C-X>bbbbb<C-A>jkuj<C-A>jb<C-A><C-A>bj<C-A><C-A><C-A>$<Left><BS>4a<BS>4<Up><BS>3<Up><BS>2<Esc>:wq<Esc><Esc>k0fya<Del>1<Esc>f;'<Esc>f'ja<Del>b<Down><BS>r<Down><BS>g<Esc>:wq<Esc>2kwwww<Del>0<Esc><Esc><Esc>f.f.i0<Esc>:wq<CR>

0 comments


Created by: @AWhiteDwarf1

327 active golfers, 1539 entries

Leaderboard (lowest score wins):
53
#211 - Cyber Security Daily News / @can_uygan

03/28/2022 at 10:52PM

53
#212 - Javier Contreras / @contranton

05/04/2022 at 06:42PM

54
#213 - Dominic Nunes / @domi91c

07/23/2021 at 03:15AM

54
#214 - Arryue / @Arryue2

07/31/2021 at 05:18PM

54
#215 - Craig Euler / @euler_craig

09/26/2021 at 02:08AM

54
#216 - cowai / @cowai

10/14/2021 at 06:51PM

55
#217 - Sergio / @SergioVl12

07/24/2021 at 05:00AM

55
#218 - e1mnos / @e1mnos

08/10/2021 at 11:20AM

55
#219 - jdfgjhsbd / @bli231957

09/04/2021 at 03:04PM

55
#220 - Chun Chanjun / @CChanjun

11/19/2021 at 01:48PM

55
#221 - sfsbeaetwafwear / @sfsbeaetwafwear

01/29/2022 at 05:21PM

55
#222 - jessepye / @jessepye

01/30/2022 at 04:14AM

55
#223 - pu๊b / @rtapayahc

03/02/2022 at 03:15PM

55
#224 - M Joc / @MJoc72389438

06/25/2022 at 05:35PM

56
#225 - Patrick Martin / @PatrickDMartin

06/29/2021 at 08:03AM

56
#226 - Michael / @thscuriousquest

07/25/2021 at 03:21PM

56
#227 - Bo Xie / @iebox

09/04/2021 at 02:53PM

56
#228 - e_e / @eleloi

02/12/2023 at 05:28PM

57
#229 - brent / @brent65628714

07/25/2021 at 01:30PM

57
#230 - Alaris Morissette / @Alaris_Villain

08/12/2021 at 05:11AM

57
#231 - philip / @philip5530

03/02/2022 at 04:17PM

57
#232 - Vinay Sridhar / @kewllip

03/12/2023 at 12:41PM

58
#233 - Henry Blevins / @HenryBlevins

07/04/2021 at 05:50PM

58
#234 - 盧小小 / @VegetaLu

04/01/2022 at 06:07PM

58
#235 - Jonathan Elliott / @jon__elliott

05/04/2022 at 09:57AM

58
#236 - Spam Mail / @mrfdot

05/26/2023 at 12:57AM

58
#237 - cykirk / @cykirk

01/15/2024 at 03:34AM

59
#238 - Theo Sarrazin / @tshaero

08/25/2021 at 08:39PM

59
#239 - Andrius / @Andrius28757706

09/03/2021 at 11:20AM

59
#240 - zeko / @zeknife

09/03/2021 at 09:34PM