+ 1
What is the error with this code? can't understand
5 odpowiedzi
+ 7
Just change else part using
n * method(n - 1)
+ 4
Replace by this in your code
if (num == 1)
return 1;
else
return(num + method(num - 1));
+ 1
🅰🅹 - ɪ'ᴍ ᴄʀɪᴍɪɴᴀʟʟʏ ɢᴏᴏᴅ! Thank you Anant
How can I get 6 as output which as factorial of 3
+ 1
Thank you 🅰🅹 - ɪ'ᴍ ᴄʀɪᴍɪɴᴀʟʟʏ ɢᴏᴏᴅ! Anant brother you are always best with Java...
0
Thank you Coder Kitten. got the exact definition what I looked for actually its a quiz in java sololearn...