time limit per test: 0.25
memory limit per test: 4096
input: standard input
output: standard output
You task is to find minimal natural number N, so that N! contains exactly Q zeroes on the trail in decimal notation. As you know N! = 1*2*...*N. For example, 5! = 120, 120 contains one zero on the trail.
One number Q written in the input (0<=Q<=10^8).
Write "No solution", if there is no such number N, and N otherwise.
|Author:||Andrew V. Lazarev
|Resource:||Saratov Subregional School Team Contest, 2002
|Server time: 2016-07-02 05:09:26||Online Contester Team © 2002 - 2016. All rights reserved.|