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 346 remaining solutions by signing in and submitting your own entry
#347 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

347 active golfers, 1660 entries

Leaderboard (lowest score wins):
47
#181 - Mark Ridings / @ridings_mark

01/25/2022 at 07:57PM

47
#182 - math is what I hate / @mpnmbn

03/13/2022 at 09:53AM

47
#183 - ff df / @ffdf93207177

04/18/2022 at 06:18AM

47
#184 - Dank City / @ddankcity

12/05/2022 at 11:38PM

48
#185 - jd / @jdseamless

09/01/2021 at 03:19PM

48
#186 - Nick Repetti / @nick_repetti

09/24/2021 at 01:02AM

48
#187 - Fabian Ahbeck / @FAhbeck

10/08/2021 at 04:22PM

48
#188 - zendokite / @zendokite

10/22/2021 at 08:39AM

48
#189 - John Other / @john_other

10/24/2021 at 04:11AM

48
#190 - auruby / @HenGreneggs

11/02/2021 at 02:53AM

48
#191 - 박덕구 / @bagdeoggu

12/05/2021 at 07:52AM

48
#192 - jebit17322 / @jebit17322

05/05/2022 at 11:41PM

48
#193 - Ryan Murphy / @RyanMur03026891

05/10/2022 at 11:46PM

48
#194 - Driver / @zhouyijiaren

06/11/2022 at 12:49PM

48
#195 - LandR / @ListenAndR

11/01/2023 at 10:31PM

48
#196 - Joris / @CheeseAndChips

05/11/2024 at 10:44PM

49
#197 - drumstix576 / @drumstix576

10/10/2021 at 10:33AM

49
#198 - literally a 🐝 / @abbie_is_here

10/29/2021 at 03:25PM

49
#199 - Jakob k. Hansen / @JakobkHansen1

04/17/2022 at 07:42PM

49
#200 - Sarang Khim / @sarang_khim

07/27/2022 at 08:37AM

49
#201 - 语冰者 / @darcysail

08/18/2022 at 04:59PM

49
#202 - JerryYe / @Jerry_Acoolda

07/03/2023 at 02:40AM

49
#203 - Flimsy Giraffe / @flimsy_giraffe

10/04/2023 at 06:59PM

50
#204 - MrRubiksSC / @RubiksSc

08/14/2021 at 02:02PM

50
#205 - Curtis Ault / @Curtis_Ault

03/18/2022 at 08:26PM

50
#206 - Henry Chimpden Earwicker / @HChEarwicker

06/14/2022 at 06:15AM

50
#207 - JWei / @JWei9

07/18/2022 at 02:41PM

50
#208 - Bas / @m1tix

09/23/2022 at 03:15PM

50
#209 - Chris Conte / @chriscconte

12/06/2022 at 10:49PM

50
#210 - Alexander Morozov / @scanhex

12/07/2022 at 09:00PM