当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。

建议使用的浏览器:

谷歌Chrome 火狐Firefox Opera浏览器 微软Edge浏览器 QQ浏览器 360浏览器 傲游浏览器

5833:Zhu and 772002

题目描述
Zhu and 772002 are both good at math. One day, Zhu wants to test the ability of 772002, so he asks 772002 to solve a math problem.

But 772002 has a appointment with his girl friend. So 772002 gives this problem to you.

There are $n$ numbers $a_1, a_2, ..., a_n$. The value of the prime factors of each number does not exceed $2000$, you can choose at least one number and multiply them, then you can get a number $b$.

How many different ways of choices can make $b$ is a perfect square number. The answer maybe too large, so you should output the answer modulo by $1000000007$.
输入解释
First line is a positive integer $T$ , represents there are $T$ test cases.

For each test case:

First line includes a number $n(1 \leq n \leq 300)$,next line there are $n$ numbers $a_1, a_2, ..., a_n, (1 \leq a_i \leq 10^{18})$.
输出解释
For the i-th test case , first output Case #i: in a single line.

Then output the answer of i-th test case modulo by $1000000007$.
输入样例
2
3
3 3 4
3
2 2 2
输出样例
Case #1:
3
Case #2:
3
来自杭电HDUOJ的附加信息
Author UESTC
Recommend wange2014

该题目是Virtual Judge题目,来自 杭电HDUOJ

源链接: HDU-5833

最后修改于 2020-10-25T23:26:01+00:00 由爬虫自动更新

共提交 0

通过率 --%
时间上限 内存上限
2000/1000MS(Java/Others) 65536/65536K(Java/Others)