#E00322. 判断素数

判断素数

Input a number nn, determine whether it is prime. If it is, output Prime, otherwise output its smallest non-1 factor.

n[2,2147483647],nZn\in [2, 2147483647], n\in \mathbb{Z}

2
Prime
6
2

We do not recommend you read the following content unless you encounter problems.

About Time Limit ExceededTime Limit Exceeded means your program has exceeded the running time limit. Consider optimizing your program. Tip: Prime numbers have factors in pairs, so if one part doesn't have a factor, neither does the other.