Difference between int fact(int n) { if (n < = 1) // base case return 1; else return n*fact(n-1); } and int fact(int n) { if (n < = 1) // base case return 1; else n*fact(n-1); }

please explain difference between when we simply call a recursive function and when we call with return statement

please reply…

Any function that does not return nothing ( void ) must encounter a return statement before running out of things to do.