#P14663. [KenOI 2025] 倍数题
[KenOI 2025] 倍数题
Description
Given queries, each contains a positive integer . Find the all of the integer that satisfy the following conditions:
- is a perfect square number
- is a multiple of
Find the quantity of .
Input Format
Each test case contains multiple data sets. You will only receive the score for a test case if you pass all its data sets.
The first line contains an integer .
The next lines each contains an integer .
Output Format
lines, the quantity of .
3
9
50
100
1
2
3
Hint
Example explanation
There are a total of three queries.
-
For the first query, is ;
-
For the second query, all are ;
-
For the third query, all are .
Data Volume and Conventions
This problem is divided into subtasks. Your score in a subtask is the minimum score across all its test cases.
This problem uses subtask dependencies. You will not receive the score for a subtask unless you achieve full points on all its dependent subtasks.
| Subtask | Score | Dependencies | |
|---|---|---|---|
| none | |||
For all of the cases, .
京公网安备 11011102002149号