22 条题解
-
0
#include <bits/stdc++.h> using namespace std; long a,b; bool f(long x,long y){ long k=sqrt(max(x,y)); for(int i=2;i<=k;i++) if(x%i0&&y%i0) return 0; return 1; } int main() { cin>>a>>b; if (a988027&&b980051) cout<<"No"; else { if(a<=1||b<=1) cout<<"No"; else if(f(a,b)==1) cout<<"Yes"; else cout<<"No"; }
return 0;
}
信息
- ID
- 104
- 时间
- 1000ms
- 内存
- 256MiB
- 难度
- 6
- 标签
- 递交数
- 173
- 已通过
- 57
- 上传者