cho.sh
Notes
Loading...

Rounding

Time limit

2s

Memory limit

128 MB

Problem

You are given an integer N. If the current value is greater than 10, round the ones digit to make it a multiple of 10. If the result is greater than 100, round the tens digit to make it a multiple of 100. Continue in the same way: whenever the current value is greater than the next threshold, round the digit immediately below that threshold.

When rounding a digit, values 5 or greater round up, and values 4 or less round down. Print the value after no more rounding steps are required.

Input

The first line contains an integer N.

0 <= N <= 99,999,999

Output

Print the value after applying the full rounding process.