Solved

Consider the Recursive Method Shown Below: Public Static Int StrangeCalc(int

Question 108

Multiple Choice

Consider the recursive method shown below: public static int strangeCalc(int bottom, int top)
{
If (bottom > top)
{
Return -1;
}
Else if (bottom == top)
{
Return 1;
}
Else
{
Return bottom * strangeCalc(bottom + 1, top) ;
}
}
What value will be returned with a call to strangeCalc(4,7) ?


A) 1
B) -1
C) 120
D) 840

Correct Answer:

verifed

Verified

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

Related Questions