Cod sursa(job #1592895)
Utilizator | Data | 8 februarie 2016 08:47:13 | |
---|---|---|---|
Problema | Factorial | Scor | 0 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.4 kb |
using namespace std;
#include <iostream>
#include <stdio.h>
#include <fstream>
int main(){
int n, copie, count = 0;
cin >> n;
for(int i = 5;;i+=5){
copie = i;
while(copie%5 == 0){
count++;
copie /= 5;
}
if(count == n){
cout<<i;
break;
}
}
return 0;
}