| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 150458 | 王显端 | 14判断素数III | C++ | Time Limit Exceeded | 1000 MS | 264 KB | 252 | 2026-03-28 11:45:03 |
#include<iostream> using namespace std; int main() { int i,n; bool flag; flag=true; cin>>n; for(i=2;i<n;){ if(n%i==0){ flag=false; break; } } if(flag==true) cout<<"是素数"<<endl; else cout<<"不是素数"<<endl; return 0; }