title: C Program Factorial Number 2
signature: long long cProgramFactorialNumber2(int n) {
test_code: #include <algorithm>
  #include <assert.h>
  #include <cstdlib>
  #include <iostream>
  #include <map>
  #include <set>
  #include <string>
  #include <tuple> 
  #include <unordered_map>
  #include <vector>
  #include <math.h>
  #include <cmath>
  #include <bits/stdc++.h>
  #include <numeric>
  #include <functional>
  
  using namespace std;
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE 
  // ============================================
  bool validateSolution(long long actual, long long expected){
      return actual == expected;
  }
  
  string driver(int n, long long expected){
      try
      {
          if (validateSolution(PLACEHOLDER_FN_NAME(n), expected)){
              return "PASSED";
          }
          return "FAILED";
      }
      catch (const std::overflow_error& exception_obj)
      {
          return typeid(exception_obj).name();
      }
      catch (const std::runtime_error& exception_obj)
      {
          return typeid(exception_obj).name();
      }
      catch (const std::exception& exception_obj)
      {
          return typeid(exception_obj).name();
      }
      catch (...)
      {
          return "UNK_ERROR";
      }
  }
  
  int main() {
      string result = "";
  
      result = driver(19, 121645100408832000); 
      cout << "TEST-" << 0 << "..."
           <<  result
           << "\n";
  
      return 0;
  }
source_py: def c_program_factorial_number_2(n):
      return (1 if ((n == 1) or (n == 0)) else (n * c_program_factorial_number_2((n - 1))))
source_cpp: int c_program_factorial_number_2(int n) {
    return ( n == 1 || n == 0 ) ? 1 : n * c_program_factorial_number_2 ( n - 1 );
  }