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

swap number pairs

Swap the numbers in a bunch of 2-element arrays.

Start file
[2, 1], [5, 4]
[6, 3]
[7, 4]
[8, 2], [12, 11]
End file
[1, 2], [4, 5]
[3, 6]
[4, 7]
[2, 8], [11, 12]

View Diff

1,4c1,4
< [2, 1], [5, 4]
< [6, 3]
< [7, 4]
< [8, 2], [12, 11]
---
> [1, 2], [4, 5]
> [3, 6]
> [4, 7]
> [2, 8], [11, 12]

Solutions by @RyanWay16:

Unlock 16 remaining solutions by signing in and submitting your own entry
Created by: @wedesoft

172 active golfers, 910 entries

Solutions by @RyanWay16:
16
#12 - Ryan Way / @RyanWay16

12/08/2020 at 11:10PM

17
#>43 - Ryan Way / @RyanWay16

12/08/2020 at 11:06PM

18
#>63 - Ryan Way / @RyanWay16

12/08/2020 at 11:05PM

19
#>63 - Ryan Way / @RyanWay16

12/08/2020 at 11:02PM

22
#>74 - Ryan Way / @RyanWay16

12/08/2020 at 10:53PM

23
#>82 - Ryan Way / @RyanWay16

12/08/2020 at 10:48PM

24
#>84 - Ryan Way / @RyanWay16

12/08/2020 at 10:48PM

25
#>87 - Ryan Way / @RyanWay16

12/08/2020 at 10:14PM

26
#>90 - Ryan Way / @RyanWay16

12/08/2020 at 09:57PM

27
#>92 - Ryan Way / @RyanWay16

12/08/2020 at 09:53PM

27
#>92 - Ryan Way / @RyanWay16

12/08/2020 at 09:54PM

30
#>104 - Ryan Way / @RyanWay16

12/08/2020 at 09:43PM

31
#>111 - Ryan Way / @RyanWay16

12/08/2020 at 09:42PM

32
#>122 - Ryan Way / @RyanWay16

12/08/2020 at 09:37PM

34
#>129 - Ryan Way / @RyanWay16

12/08/2020 at 09:35PM

36
#>135 - Ryan Way / @RyanWay16

12/08/2020 at 09:31PM