水仙花数 水仙花数,就是指一个三位数其各位数字的立方和等于该数本身 例如153 = 1^3+ 5^3 + 3^3 #include <iostream> using namespace std; int main() { int x=100; int a,b,c; for(;x<=999;x++) { a=x%10; b=(x/10)%10; c=x/100; if(x==a*a*a+b*b*b+c*c*c) cout<<x<<" "; }; return 0; } //@author xkxy