1.

What is the output of this program?
#include 
using namespace std;
long fact (long p)
{
if (p > 1)
return (p * fact (p + 1));
else
return (1);
}
int main ()
{
long n = 6;
cout << n << "! = " << fact ( n );
return 0;
}

A. 1
B. 6
C. segmentation fault
D. compile time error
E. None of these
Answer» D. compile time error


Discussion

No Comment Found