Solved

Complete the Code for the MyFactorial Recursive Method Shown Below

Question 21

Multiple Choice

Complete the code for the myFactorial recursive method shown below, which is intended to compute the factorial of the value passed to the method: public int myFactorial(int anInteger)
{
If (anInteger == 1)
{
______________________
}
Else
{
Return (anInteger * myFactorial(anInteger - 1) ) ;
}
}


A) return 0;
B) return -anInteger;
C) return 1;
D) return myFactorial(anInteger) ;

Correct Answer:

verifed

Verified

Unlock this answer now
Get Access to more Verified Answers free of charge

Related Questions