Counting adventure by nn

:cm X \ positive integer is 
:cm Y ty-
:cm L let 
:cm S =split('0
:LaSone0two0three0four0five0six0seven0eight0nine',0,1)|LbSfirst0second0third0fourth0fifth0sixth0seventh0eighth0ninth',0,1)|LcStenth0twenY0thirY0forY0fifY0sixY0sevenY0eighY0nineY',0,1)|Li=0|wh i<10|Lj=0|wh j<10|let@O='The '.c[i].b[j]."X".c[i].a[j].".\n"|Lj+=1|endw|Li+=1|endw|let@O="The one hundredthXone hundred.\n"
"aC\x12o\x1b:%s/y- /ieth 
:%s/-\./.
11G$hxhxj:.,20s/tenth//g
:14,20s/\(th \|\.\)/teen\1/g
12Gwcweleventh\x1b$bcweleven\x1b+wcwtwelfth\x1b$bcwtwelve\x1b+2esteenth\x1b$Fr3sir\x1b++$FtXhrf3jftx+ftie\x1b{dd@ajdGZZ

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page