《C语言编写的英语数字转化代码(数字转化为用英语表达的数字)》由会员分享,可在线阅读,更多相关《C语言编写的英语数字转化代码(数字转化为用英语表达的数字)(46页珍藏版)》请在金锄头文库上搜索。
1、#include“stdio.h“main ()FILE *fp ;int i ,n ,g,s;char *a20=“zero“,“one“,“two“,“three“,“four“,“five“,“six“,“seven“,“eight“,“nine “,“ten“,“eleven“,“twelve“,“thirteen“,“fourteen“,“fifteen“,“sixteen“,“seventeen“,“eighteen“,“nineteen“,*b10= “,“,“twenty“,“thirty“,“fourty“,“fifty“,“sixty“,“seventy“,“eighty“
2、,“ninety “;fp=fopen(“f:ENGLISH2.txt“,“w“) ;for (n=0;n1000;n+)i=rand()%99;if(i20)fprintf(fp,“%6sn“,ai);else if(i100)s=i/10;g=i%10;if(g=0)fprintf(fp,“%sn“,bs);else fprintf(fp,“%s-%sn“,bs,ag);fclose(fp);getch();把代码复制(ctrl+c)然后在编程软件中运行就可以出来结果!sixtentwotensixteenseventeenfifteenfifteeneightsixfoureightee
3、nelevennineteentwelvezerotwelveonethreesevennineteenonetenfivefourteennine twelveelevennineteensixteenoneelevenfifteenthirteenfourteentennineteenfifteenonetwelvenine eightsixfourtwelvethreesixfournineteenelevensevenzerofifteentwelveeightsixseventwofourteennine nine threesixoneteneighteenfivenineteen
4、tenthirteenthirteennine fivetwothirteenseventeensixteeneightzeroeighteensixteenzerotwotwosevenfifteensixteeneighteensixteennineteeneightnineteenoneseventeenfifteenonefifteenzerotenoneseventeenfifteenthreeseventwelveeleventhirteenthirteenfourteenthirteensixeighteensixtenfourfourteenelevennineteensixt
5、enfoureleventwelvefifteenthreesixfourzeroeightfournineteeneightfivesixfifteenzerothreezeroeighteensixteensevenfoureightzerothirteenfivenine threezerotwelvefiveelevennineteentwofourelevenzerotenonesixteenthreefivetwotwelvethirteeneighteentwelveoneoneonetwelvetwotwofourteeneighteenfivenine threetwelve
6、sixteenfivefivenineteenthreetwosixnine thirteennineteenseventensixthreetwelveeightseventeenthirteensixfifteensevenfourteenfiveeighteenthreethreefourteennineteenelevenelevenonenineteeneleventhreeeighteenfourteenfoursixteenthirteensevenseventwelvetwelvesixtwofivethirteenfiveeighttensevenfoursixteeneig
7、hteenfoursixsixteenfourteenonenine threesixtwozerofifteenzeroeightfifteentwelveseventeenelevensixfoureighteleveneighteenoneeleventhreesixteeneleventwonine fifteeneighteentenfifteentwofifteensixteentwosixfourteenfifteennineteensixteensixteenthreethreenine nine twonine onezerofivenine tenoneelevensixt
8、hreeelevenzerothreezerofourteneighteensevenonesixteensixnineteensixfivenineteenelevenfiveonetwosixfourteenthirteeneighteenfivenineteenfourteenonetwotwelvefiveeightzerothirteenseventeenonesevensixeightnine sixteenthreefourteensixteennineteennine twelvezerosixteenzerofoureighteenonefourteenfourthreefo
9、urteenthirteenzerosevententwelveeighttenfourelevennineteentwelvefifteensevensixeighteenthreeeleventhreeonesixteennine fourtwofivezerothreesevennine elevenfifteentwelveeighttenfivefivethirteensevenfoursevensevenseventhirteenfournine fivefifteeneighttwoelevenfourteenthirteenzeroeighteighteentenfourfou
10、rteeneighteentwelvefifteenfouronesixteennineteentwozeronine fournineteenthirteensixteentwelveeightsixteeneightthirteenseveneleventhirteenteneighteensevenfifteentwelvefiveseventeentwelvetenzeroseventeenfivenineteenfivesixfourtwoonefourteenfifteennineteentwoeighttwelvefiveonesixthirteenfifteenoneseven
11、nine nineteenthreeeleveneightfourfifteennine eleventhreethreeseventeenelevensixteenfourteeneighteensevenelevenelevenfivesixteentwosevenfourthirteeneightsixteenfivetentenseventennine seventeenzeroonefifteensixteentwelvesevenzerothreeseventwoeighteentwelveeleventwotensixteenonefifteeneightthirteentens
12、eventeenfifteenfourteenzerothirteensixteenfourseventeenseventeenthirteensevenfouronefivezerothreefourteenfourteennine fivefourteenseventeenseventeeneightoneoneeighteenseventeentwelvetwotwelveelevenzeronineteeneleventhirteenthirteenelevenfifteensixteenfourteenfoursevensevenelevennine sevenfoursixfour
13、teennineteennineteensevennine eighttwonineteenelevenseventeenfoureighteensixsixtwothreenine elevennineteenseventeensixzerosixthreeeleventhreethirteentwelvefourtenfifteenthreetwelveseventwoeightnine onefifteenonetwelvefourelevensevenfiveeightnineteenseventeentwelvethirteentenseventeeneighteenseveneig
14、htsevenfourteentwelvesixnineteententhirteensixteentenseventensevenfourteeneighteenzerozeroeighteentwoonefourelevenseveneighteentwothreethirteennineteentwothirteentwoelevensevenelevenzeroeighteeneighteenseventeeneighteeneightnineteentwonineteensevenseventeenelevenseveneighttentensixtwonine eighttwelv
15、efoureleventhreefourseveneleventwotwosixthirteenfourteenfivetwelveoneonezerofifteenonefourfivesixteenfifteenteneighteensevennineteensixfifteeneightonefourfifteenseventeensixtwelvenineteentenseventeenzerozerofourteensevensixteentenzeronineteensevenfivethirteenfourelevenfivethreeeleveneighteightsevens
16、eventeenonetwothreezerothreetwelvethreezerofifteennine eighteightfiveeighteeneightsixfourteenseveneightseventeenfifteenthirteentwelveseventeenthreetwotwotwelveelevensevenseventeentensevenfourteensixseventeennineteentwelveeightnineteensixeightsixteenseventeenelevenfourfournine threeelevenseventeenthirteentwozerotennine sixteenfivethreesixeighteenthreethirteenzerosixteenonefifteenteneighteenelevenseventeenseventeenfouronefourfourteenfivenineteenfourteenfifteenfif