Run ID:106871
提交时间:2025-01-16 22:18:58
#include <iostream> using namespace std; int main () { int m,n,f; int a,b,c; //百,十,个 f = 0; cin>>m>>n; for(int x=m;x<=n;x++) { a = x/100; c = x%10; b = x/10%10; //365-- 36 -- 6 if(a*a*a + b*b*b+c*c*c == x) { cout<<x<<" "; f =1; } } if(f==0) cout<<"no"; return 0; }