Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
124028 范恒恺 13判断质数 C++ Compile Error 0 MS 0 KB 176 2025-07-10 16:04:18

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; for(int i=2;i<n;i++){ if(n%i==0){ cout<<"No"; break; } }else{ cout<<"Yes"; } }


Run Info:

Main.cc: In function 'int main()':
Main.cc:12:2: error: 'else' without a previous 'if'
 }else{
  ^