Exam 12: Recursion
Exam 1: Introduction to Computers and Programming36 Questions
Exam 2: Input, Processing, and Output35 Questions
Exam 3: Decision Structures and Boolean Logic35 Questions
Exam 4: Repetition Structures34 Questions
Exam 5: Functions and Modules69 Questions
Exam 6: Files and Exceptions34 Questions
Exam 7: Lists and Tuples35 Questions
Exam 8: More About Strings35 Questions
Exam 9: Dictionaries and Sets35 Questions
Exam 10: Classes and Object Oriented Programming35 Questions
Exam 11: Inheritance35 Questions
Exam 12: Recursion35 Questions
Exam 13: GUI Programming35 Questions
Select questions type
The majority of repetitive programming tasks are best done with _______________.
(Short Answer)
4.9/5
(78)
In many cases a solution using recursion is more evident than a solution using a loop.
(True/False)
4.9/5
(73)
Function A calls function B, which calls function C, which calls function A. This is called _____ recursion.
(Multiple Choice)
4.7/5
(76)
A function is called from the main function and then it calls itself five times. The depth of recursion is _______________.
(Short Answer)
4.8/5
(72)
If the problem cannot be solved now, then a recursive function reduces it to a smaller but similar problem and _____.
(Multiple Choice)
4.8/5
(63)
When function A calls function B, which in turn calls function A, it is known as indirect recursion.
(True/False)
4.8/5
(78)
The base case does not require _______________, so it stops the chain of recursive calls.
(Short Answer)
5.0/5
(74)
All the cases of the recursive solution other than the base case are called the _______________ case.
(Short Answer)
4.8/5
(76)
If the problem can be solved immediately without recursion, then the recursive function _____.
(Multiple Choice)
4.9/5
(77)
A recursion in which a function directly calls itself is known as _______________ recursion.
(Short Answer)
4.8/5
(79)
A function is called from the main function for the first time. It then calls itself seven times. What is the depth of recursion?
(Multiple Choice)
4.9/5
(81)
Showing 21 - 35 of 35
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)