Cod sursa(job #2474337)

Utilizator AlexWTFAlexandru Marius AlexWTF Data 15 octombrie 2019 00:19:54
Problema Factorial Scor 5
Compilator cpp-64 Status done
Runda Arhiva de probleme Marime 0.26 kb
#include <fstream>
  using namespace std;
    ifstream in("fact.in");
    ofstream out("fact.out");
    int main () {
      int P, N;
      in >> P;
      N = 1;
      for ( int i = 1; i <= P; i++) {
        N *= i;
      }
      out << N;
      return 0;
    }