Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
12471 罗炜翰 甲乙的年龄 C++ 通过 100 1 MS 252 KB 405 2025-07-13 15:19:17

Tests(1/1):


#include<bits/stdc++.h> using namespace std; int fun(int q){ for(int i=2;i<q;i++){ if(q%i==0){ return 0; } } return 1; } int z(int x){ if(fun(x)&&x/10+x%10==13&&x<100){ return 1; } else{ return 0; } } void cmp(){ for(int i=1;i<=100;i++){ for(int j=1;j<=100;j++){ if(i-j==13&&z(i+j)){ cout<<i<<' '<<j; } } } } int main() { cmp(); }


测评信息: