素数
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Description
输入一个数,判断这个数是否是素数?
Input Format
第一行输入一个数T,表示有T组数据
接下来每行输入一个n,表示需要判断的数。
Output Format
对于每行的n,如果是素数输出"YES",否则输出"NO"。
3
109
9898563
373733771
YES
NO
NO
Hint
对于30%的数据:$ t\le 20,1\le n\le 2^{32}-1$
对于100%的数据:$ t\le 500,1\le n\le 2^{63}-1$
寒假集训_01_09
- Status
- Done
- Rule
- XCPC
- Problem
- 6
- Start at
- 2025-1-9 14:00
- End at
- 2025-1-9 17:00
- Duration
- 3 hour(s)
- Host
- Partic.
- 41