Cod sursa(job #1943961)

Utilizator alexkosaAlex Kosa alexkosa Data 28 martie 2017 21:36:01
Problema Factorial Scor 10
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.24 kb
#include <fstream>
using namespace std;
ifstream fin("fact.in");
ofstream fout("fact.out");
int main()
{int p;
fin>>p;
if(p==0)
    fout<<"1";
else if(p==1)
    fout<<"5";
else if(p==2)
    fout<<"10";
else
    fout<<5*p;
return 0;}