Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
45995 sunhuifeng 四叶玫瑰数 C++ 通过 1 MS 252 KB 263 2024-04-21 19:44:07

Tests(1/1):


#include<bits/stdc++.h> using namespace std; int main(){ int n,m; cin>>n>>m; for(int i=n;i<=m;i++){ int q,b,s,g; q=i/1000; b=i/100%10; s=i/10%10; g=i%10; if(i==(q*q*q*q+b*b*b*b+s*s*s*s+g*g*g*g)){ cout<<i<<" "; } } return 0; }


测评信息: