405008: GYM101736 H Hiking

Memory Limit:256 MB Time Limit:1 S
Judge Style:Text Compare Creator:
Submit:0 Solved:0

Description

H. Hikingtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output

Cactus is hiking with his friends in the Great Bear Rainforest. As they were too busy practicing ACM problems the night before, they forgot to bring bug spray, emergency shelter, whistles, and most importantly, food! After several dozen hours, Cactus and his friends become tired and hungry. Suddenly, Cactus spots a berry on a bush. Just as he stretches out his hand to pick it, he hears a low grumbling noise behind him. It's a Great Bear, and it's hungry... for berries!

Thinking quickly, Cactus pulls out his M4 Carbine with a M203 grenade launcher attachment and blasts the Great Bear into the Spirit Realm. Unfortunately, he forgot to stock up on bullets and grenades, so he has no projectiles left. In his panic, Cactus asks the Geometry God to estimate the probability of their survival. Clearly this is an insult to Geometry's intelligence and omnipotence, as he immediately gives Cactus the exact probability of their survival as a function of the amount of time it takes them to leave the Great Bear Rainforest.

In this equation, e is Euler's constant and t is the time it will take Cactus and his friends to escape from the Great Bear Rainforest. P(t) gives the percent probability that the group manages to leave untraumatized.

Given this equation, Cactus is faced with the impossible task of finding t. Luckily, Cactus knows exactly how long it will take them to exit the Great Bear Rainforest from his primal instincts as a Great Bear warrior in his previous life.

Due to a lack of food and safety blankets, Cactus is too hungry to think straight. Help Cactus and his friends find the probability that they will survive, and not be bearied by barely beary barbearian berry bears bearfacedly bearing down on them!

Input

The only line of input contains one integer t (1 ≤ t ≤ 106).

Output

Output P(t) for the given time. Your answer will be considered correct if the absolute error is at most 10 - 3.

ExampleInput
1
Output
98.9283067805

加入题单

上一题 下一题 算法标签: