数字和字母的转换的程序写一个叫num的程序...读或者写十进制被指定是阿拉伯数字或者是英文字母的号码..程序要一直从标准

数字和字母的转换的程序
写一个叫num的程序...读或者写十进制被指定是阿拉伯数字或者是英文字母的号码..程序要一直从标准输入里读再写标准输出直到所有输入都进行了...
1.转换 数字 into 字母 for numbers less than 10.
input output
5 five
0 zero
2.转换 数字 into 字母 for numbers less than or equal to 20.
input output
15 fifteen
12 twelve
3.转换 小写字母 into numerals for numbers less than or equal to 20.
input output
fifteen 15
eight 8
4.对于输入的字母是不敏感的
input output
FIFTEEN 15
EiGhT 8
5.转换 numerals into words for numbers less than 1000.
input output
921 nine hundred twenty one
901 nine hundred one
6.转换 字母 为 数字 for numbers less than 1000.
input output
two hundred fifty six 256
one hundred eleven 111
7.如果输入了不可用的数据则输出一个错误的信息..
input output
hello world invalid input
3 hundred invalid input
%@ invalid input
希望会的人能写一个完整的例子出来...
morningwind1984 1年前 已收到1个回答 举报

阿乐华 幼苗

共回答了16个问题采纳率:93.8% 举报

你很无聊厄

1年前

7
可能相似的问题
Copyright © 2024 YULUCN.COM - 雨露学习互助 - 16 q. 0.029 s. - webmaster@yulucn.com