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

Java to JavaScript

Let convert some simple Java file to JavaScript!

Start file
public class VimGolf
{
   public static void sayHello()
   {
      System.out.println("Hello VimGolf");
   }
   public static void main(String []args)
   {
      sayHello();      
   }
}
End file
class VimGolf
{
	static
	sayHello()
	{
		console.log("Hello VimGolf");
	}
	static
	main(args)
	{
		VimGolf.sayHello();
	}
}
VimGolf.main([]);

View Diff

1c1
< public class VimGolf
---
> class VimGolf
3,10c3,12
<    public static void sayHello()
<    {
<       System.out.println("Hello VimGolf");
<    }
<    public static void main(String []args)
<    {
<       sayHello();      
<    }
---
> 	static
> 	sayHello()
> 	{
> 		console.log("Hello VimGolf");
> 	}
> 	static
> 	main(args)
> 	{
> 		VimGolf.sayHello();
> 	}
11a14
> VimGolf.main([]);

Solutions by @JacobGelbman:

Unlock 18 remaining solutions by signing in and submitting your own entry
Created by: @thari_eth

67 active golfers, 257 entries

Solutions by @JacobGelbman:
59
#7 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:31AM

61
#>12 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:27AM

64
#>15 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:20AM

67
#>21 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:15AM

72
#>24 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:11AM

73
#>26 - jcbglbmn / @JacobGelbman

05/23/2022 at 05:04AM

74
#>28 - jcbglbmn / @JacobGelbman

05/23/2022 at 04:05AM

80
#>31 - jcbglbmn / @JacobGelbman

05/23/2022 at 04:02AM

83
#>33 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:59AM

86
#>33 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:53AM

88
#>36 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:48AM

90
#>40 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:45AM

93
#>44 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:42AM

94
#>44 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:37AM

102
#>53 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:32AM

103
#>55 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:20AM

107
#>55 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:29AM

108
#>55 - jcbglbmn / @JacobGelbman

05/23/2022 at 03:12AM