Hdu上的一道题1058,一直WA呀,为什么#include#define min(a,b) a
网友回答
while(scanf(%d,&n)&&n)
{ if (n % 10==1&&n%100!=11)
printf(The %dst humble number is %I64d.\n,n,u[n]);
else if
(n % 10==2&&n%100!=12)
printf(The %dnd humble number is %I64d.\n,n,u[n]);
else if
(n % 10==3&&n%100!=13)
printf(The %drd humble number is %I64d.\n,n,u[n]);
else printf(The %dth humble number is %I64d.\n,n,u[n]);
}似乎你输出的时候判断有点问题,这个是我写的,你看看吧.