Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
111118 | 张新福 | 13判断质数 | C++ | Wrong Answer | 1 MS | 268 KB | 218 | 2025-02-27 14:19:27 |
#include <iostream> using namespace std; int main(){ int n,i,c=0; cin>>n; for(i=2;i<=n;i++){ if(n%i==0){ c=1; break; } } if(c==0){ cout<<"Yes"; }else{ cout<<"No"; } return 0; }
------Input------
157
------Answer-----
Yes
------Your output-----
No