Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
146106 A班卞定熙 水仙花数 C++ 通过 100 0 MS 248 KB 274 2024-05-07 18:45:43

Tests(1/1):


#include<bits/stdc++.h> using namespace std; int a[5],ans; int main(){ for(int i=2;i<=1000;i++){ a[1]=i%10; a[2]=i/10%10; a[3]=i/100%10; a[4]=i/1000%10; if(a[1]*a[1]*a[1]+a[2]*a[2]*a[2]+a[3]*a[3]*a[3]+a[4]*a[4]*a[4]==i)cout<<i<<endl; } return 0; }


测评信息: