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

Generate a very basic Python constructor (fixed)

Original by @BiddulphCaleb (http://www.vimgolf.com/challenges/6019f1c4642668000cee11e8) - had some extra spaces in output file.

Start file
def __init__(self, x, y, z, rotation, color, bounciness, walking_speed, running_speed, health, defense, age, type1, type2):
End file
def __init__(self, x, y, z, rotation, color, bounciness, walking_speed, running_speed, health, defense, age, type1, type2):
    self.x = x
    self.y = y
    self.z = z
    self.rotation = rotation
    self.color = color
    self.bounciness = bounciness
    self.walking_speed = walking_speed
    self.running_speed = running_speed
    self.health = health
    self.defense = defense
    self.age = age
    self.type1 = type1
    self.type2 = type2

View Diff

1a2,14
>     self.x = x
>     self.y = y
>     self.z = z
>     self.rotation = rotation
>     self.color = color
>     self.bounciness = bounciness
>     self.walking_speed = walking_speed
>     self.running_speed = running_speed
>     self.health = health
>     self.defense = defense
>     self.age = age
>     self.type1 = type1
>     self.type2 = type2

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 182 remaining solutions by signing in and submitting your own entry
#183 铃舟 / @lingzhouVII - Score: 711 - 04/14/22 @ 13:45
jjjjjjjjjjjjjjjlllllllllllllllddidef __init__(self, x, y, z, rotation, color, bounciness, walking_speed, running_speed, health, defense, age, type1, type2):<CR>    self.x = x<CR>    self.y = y<CR>    self.z = z<CR>    self.rotation = rotation<CR>    self.color = color<CR>    self.bounciness = bounciness<CR>    self.walking_speed = walking_speed<CR>    self.running_speed = running_speed<CR>    self.health = health<CR>    self.defense = defense<CR>    self.age = age<CR>    self.type1 = type1<CR>    self.type2 = type2<Esc>kkkkkkkkkkk0lllllllli<BS><BS><BS><BS><Esc>jhhhhhhhh.u4xi<Tab><BS>    <Esc>jllllllllllhhhhhhhhhhhhhd00d0lllllllllllhhi<BS><BS><BS><BS><BS><BS><BS><BS><BS><BS><CR><Esc>kxjxhhhhhjxxjxxxjkxxxjxxxxx i  <Esc>jxxxxxxxjxxxxxxxi    <Esc>jkxjixxxxxxxxx<BS><BS><BS><BS><BS><BS><BS><BS><BS><Esc>xxxxxxxxjxxxxxxi <Esc>jxxxxxxxxxjxxxxxxxxxxi    <Esc>:wq<CR>

0 comments


Created by: @TheSchilk

183 active golfers, 828 entries

Leaderboard (lowest score wins):
50
#121 - Sithe / @SitheTie

05/05/2022 at 06:50PM

50
#122 - sdfghjk / @sdfghjk88424595

05/19/2022 at 11:28PM

50
#123 - redbigyesnoGoThenWhy / @redbigyesno

05/22/2022 at 05:59AM

50
#124 - YaruCar / @yaru_car

06/22/2022 at 11:12PM

51
#125 - fhfuih / @samhzy

05/23/2022 at 04:31AM

51
#126 - Abdelrahman Madkour / @A3Madkour

08/18/2022 at 06:14PM

51
#127 - sap / @sap38838304

09/23/2022 at 07:33PM

52
#128 - free ye / @ye1083369199

04/17/2022 at 11:51AM

52
#129 - Adam Tajti / @Devilirium

04/23/2022 at 07:15PM

52
#130 - herbage / @herbage2

04/30/2022 at 04:16AM

52
#131 - (ノ◕ヮ◕)ノ*:・゚✧ / @Mebazaa

07/02/2022 at 03:09PM

52
#132 - Nathan Iszlaub / @NIszlaub

10/21/2022 at 05:40PM

53
#133 - sean.yang / @seanyangc

03/22/2022 at 07:59AM

53
#134 - Nougatine Naja / @NougatineNaja

03/25/2022 at 01:14PM

53
#135 - Andreas Aumann / @andreasaumann

03/27/2022 at 03:08PM

53
#136 - Daniel Qu / @danielq9871

05/20/2022 at 06:59PM

53
#137 - electronjunkie / @electronjunkie

07/06/2022 at 09:32PM

54
#138 - two failing clusters in a trench coat / @0x12b

04/05/2022 at 08:54PM

54
#139 - タケ / @Take3832

04/23/2022 at 03:07PM

54
#140 - Janith Petangoda / @janithpet

08/16/2022 at 10:09PM

55
#141 - Joe Reddington / @JoeReddington

03/31/2022 at 10:20AM

55
#142 - ff df / @ffdf93207177

04/18/2022 at 01:35AM

55
#143 - David Tchanturia / @daviti85142401

05/14/2022 at 03:37PM

56
#144 - Cpt Mitten / @CptMitten

03/31/2022 at 02:32PM

56
#145 - Curtis Ault / @Curtis_Ault

04/01/2022 at 08:35PM

56
#146 - João Carvalho / @joaoCarvas

11/28/2022 at 02:14PM

58
#147 - kulabun / @kulabun

09/28/2022 at 08:03AM

59
#148 - Zach Calhoun / @ZachDCalhoun

03/27/2022 at 11:24PM

60
#149 - salchint / @salchint

05/04/2022 at 10:45PM

60
#150 - Ilay Skutelsky / @ISkutelsky

08/01/2022 at 10:15PM