QOJ.ac

QOJ

Limite de temps : 1 s Limite de mémoire : 1024 MB Points totaux : 100

#14377. Do not pour out

Statistiques

你有一个圆柱形的杯子。它的底面直径和顶面直径均为 $2$ 个单位,高度也为 $2$ 个单位。

杯中液体的高度为 $d$($0\le d\le 2$)。

当你将杯子倾斜到最大角度,且杯中的液体恰好没有溢出时,液体的表面积是多少?

输入格式

第一行是测试用例的数量。对于每个测试用例,第一行包含一个浮点数 $d$。

输出格式

对于每个测试用例,输出一行,包含液体的表面积,保留 5 位小数。

任何与标准答案的相对误差或绝对误差在 $10^{-5}$ 以内的输出都将被视为正确。

样例

输入样例 1

4
0
1
2
0.424413182

输出样例 1

0.00000
4.44288
3.14159
3.51241

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.