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

Rearrange array to single level

The goal is to flatten the array into a single list and remove any empty elements.

Start file
[
   
[]  ,
   
[''],
   
['0', '1', '2'],
   
['3', '4', '5'],
   
['6', '7'],
   
['8', '9'],
   
['']
]
End file
['', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '']

View Diff

1,9c1
< [
<     []  ,
<     [''],
<     ['0', '1', '2'],
<     ['3', '4', '5'],
<     ['6', '7'],
<     ['8', '9'],
<     ['']
< ]
---
> ['', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '']

Solutions by @sventi555:

Unlock 15 remaining solutions by signing in and submitting your own entry
Created by: @maharba6

257 active golfers, 1562 entries

Solutions by @sventi555:
14
#4 - Stephen Edwards / @sventi555

09/04/2024 at 04:41PM

15
#>18 - Stephen Edwards / @sventi555

09/04/2024 at 04:39PM

16
#>36 - Stephen Edwards / @sventi555

09/04/2024 at 04:27PM

16
#>36 - Stephen Edwards / @sventi555

09/04/2024 at 04:37PM

18
#>49 - Stephen Edwards / @sventi555

09/04/2024 at 04:21PM

19
#>67 - Stephen Edwards / @sventi555

09/04/2024 at 04:21PM

20
#>72 - Stephen Edwards / @sventi555

09/04/2024 at 04:20PM

21
#>83 - Stephen Edwards / @sventi555

09/04/2024 at 04:20PM

22
#>88 - Stephen Edwards / @sventi555

09/04/2024 at 04:17PM

23
#>96 - Stephen Edwards / @sventi555

09/04/2024 at 04:16PM

24
#>112 - Stephen Edwards / @sventi555

09/04/2024 at 04:15PM

25
#>120 - Stephen Edwards / @sventi555

09/04/2024 at 04:11PM

26
#>135 - Stephen Edwards / @sventi555

09/04/2024 at 04:08PM

27
#>143 - Stephen Edwards / @sventi555

09/04/2024 at 04:05PM

33
#>180 - Stephen Edwards / @sventi555

09/04/2024 at 04:00PM