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

Swap columns and transform to CSV format

Turn this spreadsheet output into a CSV file but first swap the columns

Start file
91	73061302-3c15-4f7d-b91b-28e6d04f99a2
28	40319da1-b92b-4170-b95a-fd494171781b
2	b18803a3-2506-4cee-beb4-51df63ca0105
64	8713cda4-deaf-43db-b3bc-08ab44b94613
95	f5cf64da-8fa1-4793-920d-91f77b882372
15	9428f144-3ec3-401e-b827-44245afd0689
69	4d08b158-279d-44e6-b10e-dafd2e1c2688
55	171f1883-4392-4d04-92f1-02923256647c
20	4fe5e7de-a7ab-4f2d-a0c7-00e9a8ee84fd
28	593bee54-df71-4c3a-b713-8295acc5d9d5
21	86ae7e83-a45e-49a2-8066-facb1c6afe8b
65	6e5aaf47-9cec-4335-9ae9-d91ba7929350
82	9031332d-a138-4bdf-94e2-ab3b51a09ebe
53	00f0fd25-46cd-4d62-b740-d853555da7f7
67	70fe1c1c-9fd1-448a-8d11-4134e92161f6
47	73021b79-85e4-4a09-8f3c-bfce5fb940c0
8	c20cd227-6efb-4978-b7be-677a6e98116f
83	6dfe55f0-942f-40af-88e3-381cfd4a97dd
91	dc1d8373-704b-45b7-8032-0763096ecfd1
57	20dd768d-13a2-4ebe-b116-a1ef3212a413
End file
73061302-3c15-4f7d-b91b-28e6d04f99a2,91
40319da1-b92b-4170-b95a-fd494171781b,28
b18803a3-2506-4cee-beb4-51df63ca0105,2
8713cda4-deaf-43db-b3bc-08ab44b94613,64
f5cf64da-8fa1-4793-920d-91f77b882372,95
9428f144-3ec3-401e-b827-44245afd0689,15
4d08b158-279d-44e6-b10e-dafd2e1c2688,69
171f1883-4392-4d04-92f1-02923256647c,55
4fe5e7de-a7ab-4f2d-a0c7-00e9a8ee84fd,20
593bee54-df71-4c3a-b713-8295acc5d9d5,28
86ae7e83-a45e-49a2-8066-facb1c6afe8b,21
6e5aaf47-9cec-4335-9ae9-d91ba7929350,65
9031332d-a138-4bdf-94e2-ab3b51a09ebe,82
00f0fd25-46cd-4d62-b740-d853555da7f7,53
70fe1c1c-9fd1-448a-8d11-4134e92161f6,67
73021b79-85e4-4a09-8f3c-bfce5fb940c0,47
c20cd227-6efb-4978-b7be-677a6e98116f,8
6dfe55f0-942f-40af-88e3-381cfd4a97dd,83
dc1d8373-704b-45b7-8032-0763096ecfd1,91
20dd768d-13a2-4ebe-b116-a1ef3212a413,57

View Diff

1,20c1,20
< 91	73061302-3c15-4f7d-b91b-28e6d04f99a2
< 28	40319da1-b92b-4170-b95a-fd494171781b
< 2	b18803a3-2506-4cee-beb4-51df63ca0105
< 64	8713cda4-deaf-43db-b3bc-08ab44b94613
< 95	f5cf64da-8fa1-4793-920d-91f77b882372
< 15	9428f144-3ec3-401e-b827-44245afd0689
< 69	4d08b158-279d-44e6-b10e-dafd2e1c2688
< 55	171f1883-4392-4d04-92f1-02923256647c
< 20	4fe5e7de-a7ab-4f2d-a0c7-00e9a8ee84fd
< 28	593bee54-df71-4c3a-b713-8295acc5d9d5
< 21	86ae7e83-a45e-49a2-8066-facb1c6afe8b
< 65	6e5aaf47-9cec-4335-9ae9-d91ba7929350
< 82	9031332d-a138-4bdf-94e2-ab3b51a09ebe
< 53	00f0fd25-46cd-4d62-b740-d853555da7f7
< 67	70fe1c1c-9fd1-448a-8d11-4134e92161f6
< 47	73021b79-85e4-4a09-8f3c-bfce5fb940c0
< 8	c20cd227-6efb-4978-b7be-677a6e98116f
< 83	6dfe55f0-942f-40af-88e3-381cfd4a97dd
< 91	dc1d8373-704b-45b7-8032-0763096ecfd1
< 57	20dd768d-13a2-4ebe-b116-a1ef3212a413
---
> 73061302-3c15-4f7d-b91b-28e6d04f99a2,91
> 40319da1-b92b-4170-b95a-fd494171781b,28
> b18803a3-2506-4cee-beb4-51df63ca0105,2
> 8713cda4-deaf-43db-b3bc-08ab44b94613,64
> f5cf64da-8fa1-4793-920d-91f77b882372,95
> 9428f144-3ec3-401e-b827-44245afd0689,15
> 4d08b158-279d-44e6-b10e-dafd2e1c2688,69
> 171f1883-4392-4d04-92f1-02923256647c,55
> 4fe5e7de-a7ab-4f2d-a0c7-00e9a8ee84fd,20
> 593bee54-df71-4c3a-b713-8295acc5d9d5,28
> 86ae7e83-a45e-49a2-8066-facb1c6afe8b,21
> 6e5aaf47-9cec-4335-9ae9-d91ba7929350,65
> 9031332d-a138-4bdf-94e2-ab3b51a09ebe,82
> 00f0fd25-46cd-4d62-b740-d853555da7f7,53
> 70fe1c1c-9fd1-448a-8d11-4134e92161f6,67
> 73021b79-85e4-4a09-8f3c-bfce5fb940c0,47
> c20cd227-6efb-4978-b7be-677a6e98116f,8
> 6dfe55f0-942f-40af-88e3-381cfd4a97dd,83
> dc1d8373-704b-45b7-8032-0763096ecfd1,91
> 20dd768d-13a2-4ebe-b116-a1ef3212a413,57

Solutions

The best way to learn is to practice. Below, you will find some of the solutions other golfers have entered. To unlock higher ranked solutions, submit your own entry which does as well or better than the solutions you can currently see - climb the ladder!

Check out these helpful resources to improve your Vim skills... Game on.

Unlock 15 remaining solutions by signing in and submitting your own entry
#16 🥚 / @schmarles_ - Score: 28 - 11/24/24 @ 16:15
:%s/\v^(\d+)\s*(.*)/\2,\1<CR>ZZ

0 comments


Created by: @pacuna

16 active golfers, 45 entries

Leaderboard (lowest score wins):
16
#1 - Danilo J. S. Bellini 🥊🇧🇷 / @danilobellini

11/22/2024 at 10:48PM

16
#2 - xscript71 / @xscript71

11/27/2024 at 09:08AM

16
#3 - GGOBP / @GG-O-BP

12/02/2024 at 07:12AM

16
#4 - Shoob / @martinshoob

12/02/2024 at 11:15AM

17
#5 - Zhenkai Weng / @tinkerrc

11/22/2024 at 01:36AM

17
#6 - Peppa Pig / @PeppaPi95550250

11/22/2024 at 01:48AM

17
#7 - Faraaz Khan / @faraazkhan

11/22/2024 at 03:54AM

17
#8 - countime / @countime

11/26/2024 at 03:29PM

17
#9 - editor3D / @editor3D

11/27/2024 at 09:39PM

17
#10 - LunaSakura / @Luna5akura

11/28/2024 at 08:18AM

17
#11 - iantalks / @iantalks

11/28/2024 at 10:16AM

17
#12 - k1mosabe / @k1mosabe

12/02/2024 at 06:50PM

18
#13 - mysper / @mysper

11/29/2024 at 08:36AM

20
#14 - Samuele Esposito / @esposm03

12/02/2024 at 08:17AM

27
#15 - Gedoy / @Gedoy9793

11/26/2024 at 11:58AM

28
#16 - 🥚 / @schmarles_

11/24/2024 at 04:15PM