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 6010dc493e0f8d0009eddcf9

Count to 100 in word form

Write all the numbers from 1 to 100, using their word forms rather than the digit form. Most of the parts you will need are included in the input file. Use hyphens when appropriate.

Start file
one two three four five six seven eight nine ten eleven twelve thirteen
twenty thirty forty fifty sixty seventy eighty ninety
hundred
End file
one
two
three
four
five
six
seven
eight
nine
ten
eleven
twelve
thirteen
fourteen
fifteen
sixteen
seventeen
eighteen
nineteen
twenty
twenty-one
twenty-two
twenty-three
twenty-four
twenty-five
twenty-six
twenty-seven
twenty-eight
twenty-nine
thirty
thirty-one
thirty-two
thirty-three
thirty-four
thirty-five
thirty-six
thirty-seven
thirty-eight
thirty-nine
forty
forty-one
forty-two
forty-three
forty-four
forty-five
forty-six
forty-seven
forty-eight
forty-nine
fifty
fifty-one
fifty-two
fifty-three
fifty-four
fifty-five
fifty-six
fifty-seven
fifty-eight
fifty-nine
sixty
sixty-one
sixty-two
sixty-three
sixty-four
sixty-five
sixty-six
sixty-seven
sixty-eight
sixty-nine
seventy
seventy-one
seventy-two
seventy-three
seventy-four
seventy-five
seventy-six
seventy-seven
seventy-eight
seventy-nine
eighty
eighty-one
eighty-two
eighty-three
eighty-four
eighty-five
eighty-six
eighty-seven
eighty-eight
eighty-nine
ninety
ninety-one
ninety-two
ninety-three
ninety-four
ninety-five
ninety-six
ninety-seven
ninety-eight
ninety-nine
one hundred

View Diff

1,3c1,100
< one two three four five six seven eight nine ten eleven twelve thirteen
< twenty thirty forty fifty sixty seventy eighty ninety
< hundred
---
> one
> two
> three
> four
> five
> six
> seven
> eight
> nine
> ten
> eleven
> twelve
> thirteen
> fourteen
> fifteen
> sixteen
> seventeen
> eighteen
> nineteen
> twenty
> twenty-one
> twenty-two
> twenty-three
> twenty-four
> twenty-five
> twenty-six
> twenty-seven
> twenty-eight
> twenty-nine
> thirty
> thirty-one
> thirty-two
> thirty-three
> thirty-four
> thirty-five
> thirty-six
> thirty-seven
> thirty-eight
> thirty-nine
> forty
> forty-one
> forty-two
> forty-three
> forty-four
> forty-five
> forty-six
> forty-seven
> forty-eight
> forty-nine
> fifty
> fifty-one
> fifty-two
> fifty-three
> fifty-four
> fifty-five
> fifty-six
> fifty-seven
> fifty-eight
> fifty-nine
> sixty
> sixty-one
> sixty-two
> sixty-three
> sixty-four
> sixty-five
> sixty-six
> sixty-seven
> sixty-eight
> sixty-nine
> seventy
> seventy-one
> seventy-two
> seventy-three
> seventy-four
> seventy-five
> seventy-six
> seventy-seven
> seventy-eight
> seventy-nine
> eighty
> eighty-one
> eighty-two
> eighty-three
> eighty-four
> eighty-five
> eighty-six
> eighty-seven
> eighty-eight
> eighty-nine
> ninety
> ninety-one
> ninety-two
> ninety-three
> ninety-four
> ninety-five
> ninety-six
> ninety-seven
> ninety-eight
> ninety-nine
> one hundred

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 28 remaining solutions by signing in and submitting your own entry
#29 李建宏 / @xx19971016 - Score: 245 - 09/04/23 @ 01:41
:%s/ /","/g<CR>y$:let b=["<C-R>0"]<CR>:s/y/een/g<CR>dtflau<Esc>0y$:let c=["<C-R>0"]<CR>ddkd$:let a=["<C-R>""]<CR>:for @a in a<CR>normal "apo<CR>endfor<CR>:<Up><Up><Up><BS>c<CR><Up><Up><Up><CR><Up><Up><Up><CR>:let a=a[0:8]<CR>for:<Esc>:for<Esc>:for @a<BS>b in b<CR>normal "bpo<CR>for !<BS>@a in a<CR>normal "bpA-<C-V><Esc>"apo<BS><BS><BS>a'<BS>po<CR>endfor<CR>endfor<CR>ddIone <Esc>ZZ

0 comments


Created by: @BiddulphCaleb

29 active golfers, 138 entries

Leaderboard (lowest score wins):
53
#1 - MonkieeBoi / @MonkieeBoi

11/21/2023 at 03:23PM

53
#2 - tien / @tien40766111

12/24/2023 at 08:17AM

53
#3 - John Braxler / @braxler

04/22/2024 at 01:22PM

53
#4 - Aly Thobani / @alythobani

05/29/2024 at 10:03AM

53
#5 - Peppa Pig / @PeppaPi95550250

07/02/2024 at 05:13AM

53
#6 - nickGPT / @nickandbro

08/24/2024 at 03:14AM

55
#7 - Topvimgolf Score / @topvimgolfscore

10/02/2023 at 06:53AM

55
#8 - Remus Dalrymple / @bornintheflames

01/02/2024 at 10:57PM

62
#9 - Georg Bökman / @BokmanGeorg

07/03/2021 at 02:56PM

62
#10 - 悟史 / @A1OBJTxN5fTg5EJ

07/13/2021 at 02:53PM

65
#11 - Miłosz Łakomy / @foobar01123

07/08/2021 at 08:29AM

65
#12 - Luoyb / @Luoyb

10/24/2023 at 08:12AM

68
#13 - quemeraisc / @quemeraisc

05/09/2022 at 12:55PM

72
#14 - vimgolfuser123 / @vimgolfuser1234

11/06/2022 at 12:54AM

72
#15 - Andrew Pritchard / @pilotInPyjamas

09/05/2023 at 11:24PM

75
#16 - treb / @treb03683130

03/18/2021 at 12:42PM

77
#17 - Smylers / @Smylers2

02/01/2021 at 09:41PM

77
#18 - HRD 센터 / @HRDCEN

10/17/2023 at 04:35PM

78
#19 - models / @zornificator

06/23/2021 at 12:51PM

78
#20 - sap / @sap38838304

07/03/2021 at 06:40PM

81
#21 - czheo / @czheo

06/08/2021 at 01:31PM

82
#22 - simplelife2010 / @simplelife20101

05/13/2021 at 02:37PM

83
#23 - Sven Kõiv / @KoivSven

05/09/2021 at 04:13PM

89
#24 - Christopher Williams / @chrstphrsnw

12/09/2021 at 10:56PM

91
#25 - かみひろ / @km_hr

03/24/2024 at 03:54AM

97
#26 - Tuure / @tuure_p

05/17/2021 at 06:49PM

97
#27 - Yondonjamts Ganzorig / @yondonjamts_g

07/24/2021 at 08:57AM

98
#28 - 马海洋 / @LG41bT7ZvqOdFl3

02/08/2023 at 02:21AM

245
#29 - 李建宏 / @xx19971016

09/04/2023 at 01:41AM