Tech Stalwarts interview question

Factorial of n number with Recursion function.

Interview Answer

Anonymous

24 May 2022

fact (int n) { if (n == 1) return 1 else return n*fact(n-1) }