Exam 12: Recursion

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

Some problems are more __________ solved with recursion than with a loop.

Free
(Short Answer)
4.9/5
(65)
Correct Answer:
Verified

easily

Recursive algorithms are always more concise and efficient than iterative algorithms.

Free
(True/False)
4.8/5
(82)
Correct Answer:
Verified

False

Each time a function is called,the system incurs __________ that is not necessary with a loop.

Free
(Short Answer)
4.8/5
(69)
Correct Answer:
Verified

overhead

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
(77)

In a recursive solution,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
(65)

The majority of repetitive programming tasks are best done with ___________.

(Short Answer)
5.0/5
(77)

If,in a recursive solution,function A calls function B which calls function C,this is called __________ recursion.

(Multiple Choice)
5.0/5
(69)

Recursive functions are __________ iterative algorithms.

(Multiple Choice)
4.9/5
(75)

The process of calling a function requires

(Multiple Choice)
4.9/5
(83)

A solution using a(n)__________ is usually more evident than a recursive solution.

(Short Answer)
4.9/5
(74)

What is the second step to take in order to apply a recursive approach?

(Multiple Choice)
4.9/5
(78)

All the cases of a recursive solution other than the base case are called the __________ case.

(Short Answer)
4.8/5
(90)

Each time a function is called in a recursive solution,the system incurs overhead that is not incurred with a loop.

(True/False)
4.9/5
(81)

If a problem can be solved immediately without recursion,then the recursive function

(Multiple Choice)
4.7/5
(88)

If a recursive solution is evident for a particular problem,and if the recursive algorithm does not slow system performance by an intolerable amount,then recursion would probably be a good design choice.

(True/False)
4.9/5
(82)

A recursive function includes __________ which are not necessary in a loop structure.

(Multiple Choice)
4.8/5
(83)

A function is called from the main function for the first time and then calls itself seven times. What is the depth of recursion?

(Multiple Choice)
4.9/5
(90)

A problem can be solved with recursion if it can be broken down into __________ problems.

(Multiple Choice)
4.9/5
(82)

A recursive function must have some way to control the number of times it repeats.

(True/False)
4.9/5
(89)

A problem can normally be solved with recursion if it can be broken down into smaller problems that are identical in structure to the overall problem.

(True/False)
4.9/5
(88)
Showing 1 - 20 of 35
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)