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 5ba4962fbbac05000bc2ddec

Preferably without multi-cursor plugin

Originally asked as question on reddit by kpthunder: https://www.reddit.com/r/vim/comments/9fvsro/what_is_the_most_efficient_way_to_go_about/

Start file
newState.set('foo', foo);
newState.set('bar', bar);
newState.set('banana', banana);
newState.set('bears', bears);
End file
state.foo = payload.foo;
state.bar = payload.bar;
state.banana = payload.banana;
state.bears = payload.bears;

View Diff

1,4c1,4
< newState.set('foo', foo);
< newState.set('bar', bar);
< newState.set('banana', banana);
< newState.set('bears', bears);
---
> state.foo = payload.foo;
> state.bar = payload.bar;
> state.banana = payload.banana;
> state.bears = payload.bears;

Solutions by @maximil61408276:

Unlock 10 remaining solutions by signing in and submitting your own entry
Created by: @argshook

114 active golfers, 459 entries

Solutions by @maximil61408276:
30
#11 - maximilian / @maximil61408276

05/23/2019 at 09:56PM

31
#>24 - maximilian / @maximil61408276

05/23/2019 at 09:48PM

32
#>39 - maximilian / @maximil61408276

05/23/2019 at 09:47PM

33
#>44 - maximilian / @maximil61408276

05/23/2019 at 09:46PM

34
#>48 - maximilian / @maximil61408276

05/23/2019 at 09:43PM

36
#>68 - maximilian / @maximil61408276

05/22/2019 at 06:26PM

37
#>74 - maximilian / @maximil61408276

05/22/2019 at 06:25PM

38
#>80 - maximilian / @maximil61408276

05/22/2019 at 06:23PM

39
#>87 - maximilian / @maximil61408276

05/22/2019 at 05:47PM

40
#>92 - maximilian / @maximil61408276

05/22/2019 at 05:45PM