Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
115633 | 谭哲曦 | 13判断质数 | C++ | Wrong Answer | 0 MS | 280 KB | 295 | 2025-04-01 21:26:05 |
#include<iostream> using namespace std; int main() { int n,i; bool flag=true; cin>>n; for(i=2;i<n;i++) { if(n%i==0){flag=false;} else{flag=true;} } if(flag) cout<<"Yes"<<endl; else cout<<"No"<<endl; return 0; }
------Input------
560
------Answer-----
No
------Your output-----
Yes