title: Program For Factorial Of A Number 2
signature: fun programForFactorialOfANumber2(n: Int): Int {
test_code: package main
  
  import kotlin.text.*
  import kotlin.math.*
  
  
  // SOLUTION CODE
  // ===================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE
  // ===================================
  fun validateSolution(actual:Int, expected:Int):Boolean{
    return actual.equals(expected)
  }
  fun driver(n: Int, expected:Int):String {
      try{
        if (validateSolution(PLACEHOLDER_FN_NAME(n), expected)) {
                return "PASSED"
        }
        return "FAILED"
      } catch (e: Exception){
        return e::class.simpleName as String
      }
  
  }
  
  fun main() {
      var result: String = ""
      result = driver(2, 2)
      println("TEST-0...${result}")
      
      result = driver(12, 479001600)
      println("TEST-1...${result}")
      
      result = driver(11, 39916800)
      println("TEST-2...${result}")
      
          
  }
  
  main()
source_py: def program_for_factorial_of_a_number_2(n):
      return (1 if ((n == 1) or (n == 0)) else (n * program_for_factorial_of_a_number_2((n - 1))))
source_cpp: int program_for_factorial_of_a_number_2(int n) {
    return ( n == 1 || n == 0 ) ? 1 : n * program_for_factorial_of_a_number_2 ( n - 1 );
  }