QOJ.ac

QOJ

حد الوقت: 1.0 s حد الذاكرة: 512 MB مجموع النقاط: 100 قابلة للهجوم ✓

#12841. 水雉数

الإحصائيات

我们定义 Jacana 数如下:

$$J(n, 1) = n$$ $$J(n, k) = n^{J(n, k-1)} \text{ 对于 } k > 1$$

我们有两个 Jacana 数:$J(n, a)$ 和 $J(m, b)$。你的任务是比较它们的大小。

输入格式

第一行包含一个整数 $T$,表示测试用例的数量 ($1 \le T \le 10^4$)。 每个测试用例包含四个整数:$n, a, m$ 和 $b$ ($1 \le n, a, m, b \le 10^9$)。

输出格式

对于每个测试用例,输出一行,包含一个字符:

  • 如果 $J(n, a) > J(m, b)$,输出 “>”;
  • 如果 $J(n, a) = J(m, b)$,输出 “=”;
  • 如果 $J(n, a) < J(m, b)$,输出 “<”。

样例

样例输入 1

3
2 2 3 1
2 3 3 2
1 2 1 4

样例输出 1

>
<
=

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.