Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
分享我的输出格式控制方法printf("The %d",n); if(n % 10 == 1){ if(n % 100 == 11) printf("th"); else printf("st"); } else if(n % 10 == 2){ if(n % 100 == 12) printf("th"); else printf("nd"); } else if(n % 10 == 3){ if(n % 100 == 13) printf("th"); else printf("rd"); } else printf("th"); printf(" humble number is %d.\n",Humble[n]); Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator