Skip to main content
Tuesday (24.11.2026) at 20:00: ALGOR Contest: Round #4 (Special Challenge) starts!

~/algor $ cat problems/while-sportchi-yugurishi

Athlete's runs

Easy 1000 ms 64 MB 28%
Share

On the first day an athlete ran $10$ km, and every next day runs $p$ percent more than the day before. On which day will the athlete first run more than $20$ km in a day? Find the number of that day $k$ and the total distance run from day $1$ to day $k$ (both inclusive).

The daily distance and the total distance covered

Input

One real number $p$ — the daily growth percentage.

Output

One line with two numbers separated by a space: the integer $k$ and the total distance with exactly 2 digits after the decimal point (for example, 9 135.79).

Note

$1.0 \le p \le 49.0$

Examples

Input #1
10.0
Output #1
9 135.79
Input #2
20.0
Output #2
5 74.42

Sign in to submit a solution

Signing up is free and takes a minute.