QOJ.ac

QOJ

时间限制: 1 s 内存限制: 1024 MB 总分: 100

#2965. RSA 错误

统计

RSA 数(RSA number)是一个正整数 $n$,它是两个不同素数的乘积。例如,$10 = 2 \cdot 5$ 和 $77 = 7 \cdot 11$ 是 RSA 数,而 $7 = 7$,$9 = 3 \cdot 3$ 和 $105 = 3 \cdot 5 \cdot 7$ 则不是。

你正在教授一门涵盖 RSA 加密的课程。在一次作业中,你要求学生生成 RSA 数。他们需要提交两个正整数 $A$ 和 $B$。理想情况下,这两个数应该是不同的素数。但有些学生提交了错误的答案。如果它们不是不同的素数,那么如果 $A \cdot B$ 对于任何整数 $k \ge 2$ 都不是 $k^2$ 的整数倍,则可以获得部分学分。如果存在一个整数 $k \ge 2$ 使得 $k^2$ 整除 $A \cdot B$,则学生将无法获得任何学分。

对于学生提交的一对正整数,请确定他们应该获得满分(full credit)、部分学分(partial credit)还是零分(no credit)。

说明:在下方的第六个样例中,数字 $545\,528\,636\,581 \cdot 876\,571\,629\,707$ 可被 $1\,000\,003^2$ 整除;在第七个样例中,数字 $431\,348\,146\,441 \cdot 3$ 可被 $656\,771^2$ 整除。

输入格式

输入包含一行,包含两个整数 $A$ ($2 \le A \le 10^{12}$) 和 $B$ ($2 \le B \le 10^{12}$),即学生提交的两个数字。

输出格式

显示学生提交的数字应该获得 full creditpartial credit 还是 no credit

样例

输入 1

13 23

输出 1

full credit

输入 2

35 6

输出 2

partial credit

输入 3

4 5

输出 3

no credit

输入 4

17 17

输出 4

no credit

输入 5

15 21

输出 5

no credit

输入 6

545528636581 876571629707

输出 6

no credit

输入 7

431348146441 3

输出 7

no credit

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.