#P9063. [yLOI2023] 分解只因数
[yLOI2023] 分解只因数
Problem Description
Given a positive integer , factorize into prime factors.
Let $n = p_1 \times p_2 \times p_3 \times \dots \times p_x$, where each is a prime number.
If all are odd, then is called a “Zhi Factor Number” (“只因数”).
Now, given several values of , determine whether is a “Zhi Factor Number”.
Input Format
This problem contains multiple groups of testdata within a single test case.
The first line contains an integer , the number of testdata groups.
The next lines each contain an integer , representing one group of data.
Output Format
For each group of data, output one string per line. If is a “Zhi Factor Number”, output Yes; otherwise output No.
5
2
3
4
6
9
No
Yes
No
No
Yes
Hint
Constraints
There are test points in total. For the -th test point, .
- For of the data, .
- For of the data, .
- For another of the data, is odd.
- For another of the data, is even.
- For of the data, .
- For of the data, , .
Notes
There are two additional sample files for this problem. See ibvl.zip in the attachments.
Translated by ChatGPT 5