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 254 remaining solutions by signing in and submitting your own entry
#255 铃舟 / @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: @philipp_schilk

255 active golfers, 1215 entries

Leaderboard (lowest score wins):
42
#121 - Daniel Niemczyk / @Adentalis

12/10/2023 at 02:43PM

43
#122 - samsepiol / @samsepi81094451

04/01/2022 at 04:48PM

43
#123 - Jason Kuan | jasonkuan.eth / @Jason9075Kuan

04/03/2022 at 09:23AM

43
#124 - Andrew Morris / @andrew_morris

07/14/2022 at 02:58AM

43
#125 - Laughing Cavalier / @jovial_cavalier

10/26/2022 at 02:45PM

43
#126 - 马海洋 / @LG41bT7ZvqOdFl3

02/07/2023 at 04:45AM

43
#127 - e_e / @eleloi

02/10/2023 at 08:58PM

43
#128 - Иван / @wansmer

04/22/2023 at 10:28PM

43
#129 - Milan Blažek / @Somin13

09/05/2023 at 09:28PM

43
#130 - BlockLune / @BlockLune

01/08/2024 at 08:44AM

44
#131 - Pierre-Olivier Proulx / @PierreO57066096

04/18/2022 at 01:08AM

44
#132 - José Medrano / @happylilmexican

05/04/2022 at 03:56PM

44
#133 - Lanly / @1094916227

05/09/2022 at 03:14AM

44
#134 - iwataka / @iwataka33

05/15/2022 at 02:06PM

44
#135 - Mario / @MarioWolfe

06/16/2022 at 04:54AM

44
#136 - サイシ / @tairar_314

06/24/2022 at 03:22AM

44
#137 - Andrew Liu / @AndrewL45936893

09/13/2022 at 10:03PM

44
#138 - Fergus Fettes / @FergusFettes

10/14/2022 at 08:40AM

44
#139 - 스치 / @champemunasong

10/27/2022 at 05:27AM

44
#140 - RosaTryp / @RosaTryp

03/14/2023 at 12:11PM

44
#141 - jasonlee / @jasonle61136657

06/07/2023 at 12:24AM

44
#142 - Игорь Квачёнок / @IKvacenok

06/11/2023 at 07:24PM

45
#143 - FeAx / @_FeAx_

03/27/2022 at 04:36PM

45
#144 - Javier Contreras / @contranton

05/04/2022 at 06:58PM

45
#145 - Ryan Murphy / @RyanMur92693753

05/13/2022 at 12:58AM

45
#146 - Tim / @MarhjaKhazua

05/14/2022 at 09:51AM

45
#147 - Austin Willliams / @GuitarMusash616

09/21/2022 at 05:49AM

45
#148 - Wüstengecko / @Wuestengecko

02/17/2023 at 03:46PM

45
#149 - SmoggyFog / @SmoggyFog

06/01/2023 at 06:47PM

45
#150 - Sebastian Steenssøe / @VildMedPap

02/18/2024 at 11:23PM