Cod sursa(job #13441)
Utilizator | Data | 6 februarie 2007 18:00:06 | |
---|---|---|---|
Problema | Factorial | Scor | 5 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.44 kb |
#include<fstream>
using namespace std;
long int n,p,m,q;
int main()
{
ifstream in("fact.in");
in>>p;
/*n=5;
q=p;
q--;
while(q)
{
n=n+5;
m=n;
while(m%5==0)
{
q--;
m=m/5;
}
}*/
ofstream out("fact.out");
/*if (p==0)
out<<1;
else*/
out<<p*5;
return 0;
}