Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Filter
Profile
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
Answers by abhishek29
0
votes
1
GO Classes 2023 | Weekly Quiz 4 | Question: 20
What will be output printed by $\text{mystery}2(6)$? void mystery2(int n) { if (n > 0) { printf("%d", n); mystery2(n-2); mystery2(n-3); printf("%d", n); } }
What will be output printed by $\text{mystery}2(6)$?void mystery2(int n) { if (n 0) { printf("%d", n); mystery2(n-2); mystery2(n-3); printf("%d", n); } }
528
views
answered
Mar 26, 2022
Programming in C
goclasses_wq4
goclasses
programming
programming-in-c
recursion
numerical-answers
1-mark
+
–
4
votes
2
GO Classes 2023 | Weekly Quiz 4 | Question: 22
Consider the following pair of mutually recursive functions. What does $g(g(2))$ evaluate to? int f(int n){ if (n==0) return 0; return f(n-1)+g(n-1); } int g(int n){ if (n==0) return 1; return g(n-1) + f(n); }
Consider the following pair of mutually recursive functions. What does $g(g(2))$ evaluate to?int f(int n){ if (n==0) return 0; return f(n-1)+g(n-1); } int g(int n){ if (n...
880
views
answered
Mar 26, 2022
Programming in C
goclasses_wq4
goclasses
programming
programming-in-c
recursion
numerical-answers
2-marks
+
–
2
votes
3
GO Classes 2023 | Weekly Quiz 4 | Question: 21
What will be the output printed by $\text{mystery}3(6)$? void mystery3(int n) { if (n == 0 || n == 1) return; mystery3(n-2); printf("%d", n); mystery3(n-1); }
What will be the output printed by $\text{mystery}3(6)$?void mystery3(int n) { if (n == 0 || n == 1) return; mystery3(n-2); printf("%d", n); mystery3(n-1); }
584
views
answered
Mar 26, 2022
Programming in C
goclasses_wq4
goclasses
programming
programming-in-c
recursion
numerical-answers
1-mark
+
–
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register