Cod sursa(job #2899815)
| Utilizator | Data | 9 mai 2022 09:30:01 | |
|---|---|---|---|
| Problema | Factorial | Scor | 10 |
| Compilator | cpp-64 | Status | done |
| Runda | Arhiva de probleme | Marime | 0.27 kb |
#include <fstream>
using namespace std;
ifstream fin("fact.in");
ofstream fout("fact.out");
int main()
{
long long n,T;
fin>>T;
if(T==0)
fout<<1;
else if(T%5==0)
fout<<(T-1)*5;
else
fout<<T*5;
return 0;
}
