Factorials#7095

Factorials

1 second
32 megabytes
Easy

The President of the First National Bank, Major Thomas B. Kingman, transfers the contents of the safes, where the bank's clients store their valuables, every night. The robbers are aware of this routine, so they rented one of the safes in the bank, waiting for the president to mistakenly transfer something valuable into their safe. This strategy paid off when they got their hands on a box containing the major's own jewels! Now, the robbers have only a few hours to crack the three-digit combination lock, take the valuables, and return the box without anyone noticing the theft.

Knowing the major's fondness for large numbers, the robbers are convinced that the code is the three consecutive digits of the number , located just before the trailing zeros at the end of . For example:

Given a natural number , determine the three consecutive digits of that appear directly before the zeros at the end of .

Input

The input file contains a single integer , where 7 \le N \le 1000000000.

Output

The output file must contain exactly three digits — the code you are looking for.

Examples

Example 1

Loading
Loading