Computer Science, asked by ajaypr2911, 1 month ago

Find the output of the below program: #include int fun(int a, int b) { if (b == 0) { return 0; } if (b% 2 == 0) { return fun(a++, b/2); } return fun(a+a, b/2) + a; } int main() { int x=10y=7; int z=fun(y,x); printf("%d",z); return 0; }​

Answers

Answered by sweetyani272
19

Explanation:

b% 2 == 0) { return fun(a++, b/2); } return fun(a+a, b/2) + a; } int main() { int x=10y=7; int z=fun(y,x); printf("%d",z); return 0; }

Similar questions