Recursion in C language MCQs

@T-Bone

This question paper focuses on the "Recursion" of the C programming. These Multiple Choice Questions (mcq) should be practiced to improve the C programming skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

This question paper focuses on the "Recursion" of the C programming. These Multiple Choice Questions (mcq) should be practiced to improve the C programming skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

Questions

1. The process in which a function calls itself directly or indirectly is called?

Mark the correct option

2. A function fun is called __________ if it calls the same function fun.

Mark the correct option

3. Which of the following is not an example of recursion?

Mark the correct option

4. When any function is called from main(), the memory is allocated to it on the stack.

Mark the correct option

5. Iteration requires more system memory than recursion.

Mark the correct option

6. When a recursive function is called in the absence of an exit condition, it results in an infinite loop due to which the stack keeps getting filled(stack overflow). This results in a run time error.

Mark the correct option

7. The data structure used to implement recursive function calls _____________

Mark the correct option

8. What will be output for the following code? #include <stdio.h> main() { int num=5; int fun(int num); printf(""%d"",fun(num)); } int fun(int num) { if(num>0) return(num+fun(num-2)); }

Mark the correct option

9. What will be output for the following code? int main() { printf(""Hello""); main(); return 0; }

Mark the correct option

10. Which of the following is true about recursion?

Mark the correct option

Index of Questions