Run ID:69409
提交时间:2024-04-02 21:36:05
#include<iostream> using namespace std; int main() { int m, b=0; cin >> m; if(m>1 && m<100000000){ for (int i = 1; i <= m; i++) { if (m % i == 0) { b += 1; } } if (b == 2) { cout << "prime"; } else { cout << "not prime"; } } }