Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
Boring solution in Clear category for Speech Module by Vulwsztyn
F = ["one", "two", "three", "four", "five", "six", "seven",
"eight", "nine"]
S = ["ten", "eleven", "twelve", "thirteen", "fourteen", "fifteen",
"sixteen", "seventeen", "eighteen", "nineteen"]
O = ["twenty", "thirty", "forty", "fifty", "sixty", "seventy",
"eighty", "ninety"]
H = "hundred"
def checkio(n):
o=''
if(n>99):
o+=F[n//100-1]+' '+H
n=n%100
print (n)
if (n>19):
if o!="":
o+=" "
o+=O[n//10-2]
n=n%10
print (n)
if n>9:
if o!="":
o+=" "
o+=S[n-10]
n=0
if n>0:
if o!="":
o+=" "
o+=F[n-1]
return o
Oct. 31, 2016