得出1,8,729,370,371,378,1099,怎么不是水仙花数
#include<stdio.h>
int main( )
{
int num,sd,td,hd;
for (num=100;num<=999;++num)
{
sd=num%10;
td=num%100/10;
hd=num/100;
if (num=hd*hd*hd+td*td*td+sd*sd*sd)
{
printf("%d\n",num);
}
}
return 0;
}