Enumeration and Recursion
Quiz
•
Computers
•
11th Grade - University
•
Medium
Carol Luce
Used 21+ times
FREE Resource
12 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Why do you need to use a base case?
So that the code loops forever
So that the code does not loop forever
To exit the recursive function
To call another function
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is the best definition of a recursive method?
A method that iterates itself exactly 5 times.
A method that invokes itself by name within the method.
A method that will never iterate infinitely.
A method that cannot be called more than once.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A program may run out of memory in a:
non-recursive function call
recursive function call
condition when too many variables are declared
none of the above
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following condition is true?
Recursion is always better than iteration.
Recursion uses more memory as compared to iteration.
Recursion uses less memory as compared to iteration.
Iteration is always better and simpler than recursion.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following problems MAY be solved using recursion?
finding Nth number of the Fibonacci sequence
finding the factorial of a number
finding the length of a string
all of the above
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Recursion is similar to which of the following?
if-else
switch-case
loops
none of the above
7.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Which of the following algorithms use recursion?
Linear Search
Binary Search
Merge sort
Insertion sort
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?
Similar Resources on Wayground
15 questions
Databases
Quiz
•
11th Grade
10 questions
Data Engineering y BigQuery V1
Quiz
•
12th Grade
15 questions
Chapter 3: Storage devices and media (Part 2):
Quiz
•
10th - 11th Grade
16 questions
Algo Quiz
Quiz
•
University
10 questions
Server Administration- Quiz 1
Quiz
•
12th Grade - University
11 questions
Computer Science (1-9) - Identifying & Preventing Threats
Quiz
•
University
10 questions
Quiz 9 (15.09.2021)
Quiz
•
1st - 12th Grade
10 questions
Windows 10 Basics
Quiz
•
9th - 12th Grade
Popular Resources on Wayground
20 questions
Halloween Trivia
Quiz
•
6th - 8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Order of Operations
Quiz
•
5th Grade
20 questions
Halloween
Quiz
•
5th Grade
16 questions
Halloween
Quiz
•
3rd Grade
12 questions
It's The Great Pumpkin Charlie Brown
Quiz
•
1st - 5th Grade
20 questions
Possessive Nouns
Quiz
•
5th Grade
10 questions
Halloween Traditions and Origins
Interactive video
•
5th - 10th Grade
