Pagini recente » Cod sursa (job #1007097) | Cod sursa (job #1899070) | Cod sursa (job #1953117) | Cod sursa (job #2613806) | Cod sursa (job #2313862)
program cc; type tabel=array[1..1000000]of 0..1;
var a,i,x,y,n,b,max,min,m,j:longint; t:tabel;
begin
assign(input,'fact.in');assign(output,'fact.out');reset(input);
rewrite(output);
readln(n);
if n=0 then write('1') else begin i:=1;
repeat
inc(i);
a:=i;
while a mod 2=0 do begin inc(x); a:=a div 2; end;
while a mod 5=0 do begin inc(y); a:=a div 5;end;
if x>y then m:=y else m:=x;
until m=n;
write(i); end;
close(input); close(output);
end.