Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
126819 何松羽 素数判断 C++ Compile Error 0 MS 0 KB 292 2025-07-22 11:09:15

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int s = 1; for (int i = 2; i <= n - 1; i++) { if (n % i == 0) { s = 0; break; } } if (s == 0) { cout << "not prime" << endl; } else { cout << "prime" << endl; } return 0; }


Run Info: