АВТ
Language:

Remote Training on Programming

Problems On-line status Contests FAQ
For authors:
Register  ||  Login
 
Hello, Guest! Login or register.

987. А119(В)

Time Limit: 1 seconds
Memory Limit:65536KB
Points:2
View Problem Statistics Submit Problem added Undefined

Вычислить бесконечную сумму с заданной точнотью E(E>0). Считать что требуемая точность достигнута, если несколько первых слагаемых и очередное слагаемое оказалось по модулю меньше, чем E, это и все последующие слагаемые можно уже не учитывать.


Input

Одно число точность E(E>0).

Output

Одно число - ответ

Sample

InputOutput
Пример 1. Вход:
0.1
Пример 1. Выход:
0.375

View Problem Statistics Submit Author/source:
Educational Courses / New problems in testing /
981. А(69) 987. 958. А78(д) 1054. Арифметическое вычисление 1040. Бесконечная сумма
We can all benefit by doing occasional "toy" programs, when artificial restrictions are set up, so that we are forced to push our abilities to the limit. The art of tackling miniproblems with all our energy will sharpen our talents for the real problems. Donald E. Knuth.
time generating 0.125 sec.
© Copyright VSTU, AVT, Nosov D.A.