Pagini recente » Cod sursa (job #2465882) | Cod sursa (job #96503) | Cod sursa (job #1133149) | Cod sursa (job #2170367) | Cod sursa (job #387558)
Cod sursa(job #387558)
var p,n,s,x:longint;
f,g:text;
begin
assign(f,'fact.in');reset(f);
assign(g,'fact.out');rewrite(g);
readln(f,p);
if (p>=1) and (p<6) then begin n:=5; s:=1; end;
if (p>=6) and (p<31) then begin n:=25; s:=6; end;
if (p>=31) and (p<156) then begin n:=125; s:=31; end;
if (p>=156) and (p<781) then begin n:=625; s:=156; end;
x:=n+ (p-s)*5;
writeln(g,x);
close(f);close(g);
end.