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 @FinnFrancis:

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

114 active golfers, 459 entries

Solutions by @FinnFrancis:
31
#21 - Finn Francis / @FinnFrancis

10/27/2018 at 01:33AM

32
#>37 - Finn Francis / @FinnFrancis

10/27/2018 at 01:30AM

33
#>41 - Finn Francis / @FinnFrancis

10/27/2018 at 01:27AM

34
#>48 - Finn Francis / @FinnFrancis

10/27/2018 at 01:23AM

35
#>50 - Finn Francis / @FinnFrancis

10/27/2018 at 01:20AM

37
#>71 - Finn Francis / @FinnFrancis

10/27/2018 at 01:08AM

37
#>71 - Finn Francis / @FinnFrancis

10/27/2018 at 01:15AM

40
#>91 - Finn Francis / @FinnFrancis

10/27/2018 at 01:05AM

42
#>96 - Finn Francis / @FinnFrancis

10/27/2018 at 01:02AM