/ AOCode / 题库 /

Mission 2 - F1: pmurT Ques(1)

Mission 2 - F1: pmurT Ques(1)

P1032 Mission 2 - F1: pmurT Ques(1)

Problem Background

Radar finally gets to the country and is now meeting pmurT. pmurT gives Radar several questions for Radar to answer.

Radar answered all of them. Can you answer it?

Problem Statement

Here’s pmurT’s \(1^{st}\) problem:

Known \(A=x^2+x+1\), given \(A\), find the positive number \(x\). (Keep \(2\) decimal places in output)

Constraints

  • \(0 \le A \le 10000\)
  • \(A\) is an integer.

Input

\(A\)

Output

\(x\)

If there’s no possible positive number \(x\), print \(-998244353\).

Samples

No samples needed!!!!!

Hint

Draw the function graph of \(A\) and \(x\) (\(x\) -> \(X\)-axis, \(A\) -> \(Y\)-axis):

p1032hint1.png

Just look at its part with positive \(x\)s - can you think of something through it?

信息

ID
1032
难度
650
分类
(无)
标签
递交数
78
已通过
11
通过率
14%
上传者

相关

在下列训练计划中:

AOSC Problems

在下列比赛中:

AOCode Round #3 & AOSC #2