| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 84212 | 刘宇轩 | 哥德巴赫猜想 | C++ | Output Limit Exceeded | 8 MS | 260 KB | 342 | 2024-07-15 14:17:51 |
#include<bits/stdc++.h> using namespace std; int a(int b){ for(int i=2;i<=b;i++){ if(b%i==0){ return 1; } } return 0; } int main() { int k; for(int i=6;i<=100;i=i+2){ for(int j=3;j<i;j=j+2){ k=i-j; if(a(j)==1&&a(k)==1){ cout<<i<<"="<<j<<"+"<<k<<endl; } } } return 0; }