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

Swap function parameters and delete all comments in python.

Swap function parameters and delete all comments in python.

Start file
# caculate area
def calculate_area(width, height): # width, height
    return width * height # return area

area1 = calculate_area(5, 10)
area2 = calculate_area(8, 12)
End file
def calculate_area(height, width):
    return width * height

area1 = calculate_area(5, 10)
area2 = calculate_area(8, 12)

View Diff

1,3c1,2
< # caculate area
< def calculate_area(width, height): # width, height
<     return width * height # return area
---
> def calculate_area(height, width):
>     return width * height

Solutions by @doggopwn:

Unlock 11 remaining solutions by signing in and submitting your own entry
Created by: @skywalkerwhack

235 active golfers, 956 entries

Solutions by @doggopwn:
19
#49 - Oliver Novák / @doggopwn

08/21/2026 at 11:00AM

19
#>49 - Oliver Novák / @doggopwn

08/21/2026 at 11:34AM

19
#>49 - Oliver Novák / @doggopwn

08/21/2026 at 11:35AM

20
#>70 - Oliver Novák / @doggopwn

08/20/2026 at 12:11PM

20
#>70 - Oliver Novák / @doggopwn

08/21/2026 at 10:56AM

21
#>80 - Oliver Novák / @doggopwn

08/20/2026 at 12:09PM

22
#>85 - Oliver Novák / @doggopwn

08/20/2026 at 12:07PM

24
#>97 - Oliver Novák / @doggopwn

08/20/2026 at 12:06PM

25
#>111 - Oliver Novák / @doggopwn

08/20/2026 at 12:04PM

27
#>129 - Oliver Novák / @doggopwn

08/20/2026 at 12:02PM

29
#>146 - Oliver Novák / @doggopwn

08/20/2026 at 12:01PM