New course! Every coder should learn Generative AI!
Try a free lesson+ 1
Why output is 120
int factorial(int n) { if (n==1) { return 1; } else { return n * factorial(n-1); } } int main() { cout << factorial(5); } //Outputs 120
2 Answers
+ 1
Why output is 120🤔