#include using namespace std; using NumberT = unsigned long long int; //typedef int NumberT; //typedef long NumberT; NumberT Factorial(int n); int main() { int i; for(i = 0 ; i < 22; i++) { cout << i << "! = " << Factorial(i) << endl; } return 0; } NumberT Factorial(int n) { NumberT result{1}; int i; for(i = 2; i <= n; i++) { result *=i; } return result; }