시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 (추가 시간 없음) 1024 MB (추가 메모리 없음)162958363.846%

문제

Yunee is taking a physics lab class. One day, after an experiment, Yunee noticed that some figures in the experiment result came out lower than expected. So Yunee decided to manipulate the result by rounding the values several times.

When rounding a number to the $i$-th place, it is rounded down if the digit one place right to the $i$-th place is less than $5$. Otherwise, it is rounded up. For example, rounding $454$ to the nearest tens gives $450$. On the other hand, rounding $454$ to the nearest hundreds gives $500$.

By rounding $454$ to the nearest hundreds and then thousands, we get $454 \rightarrow 500 \rightarrow 1000$. This is the maximum value we can get by rounding $454$ zero or more times.

Help Yunee maximize the value in the experiment result by rounding it zero or more times.

입력

The first line contains an integer $N$ representing the value in the experiment result $(1\le N \le 10^{15})$. Note that $N$ may exceed the 32-bit integer limit.

출력

Output the maximized value by rounding $N$ zero or more times. The output should not have leading zeros.

예제 입력 1

454

예제 출력 1

1000

예제 입력 2

4445

예제 출력 2

10000

예제 입력 3

1234321

예제 출력 3

1234321

출처

University > UNIST > 3rd UNIST Algorithm Programming Contest Uni-CODE 2021 B번