Recurrence Relations and Master Theorem Quiz

Recurrence Relations and Master Theorem Quiz

University

13 Qs

quiz-placeholder

Similar activities

BCSC0006 Trees

BCSC0006 Trees

University

10 Qs

Stack & Queue

Stack & Queue

University

16 Qs

Hashing

Hashing

University

10 Qs

Algorithms Data

Algorithms Data

University

15 Qs

HEAP TREE

HEAP TREE

University

11 Qs

Python 101

Python 101

University

15 Qs

Microsoft Word Masterclass

Microsoft Word Masterclass

University

15 Qs

ANALYSIS OF ALGORITHMS

ANALYSIS OF ALGORITHMS

University

15 Qs

Recurrence Relations and Master Theorem Quiz

Recurrence Relations and Master Theorem Quiz

Assessment

Quiz

Computers

University

Easy

Created by

Seven Castueras

Used 1+ times

FREE Resource

13 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is a recurrence relation in the context of algorithm analysis?

A loop-based computation formula

An equation that describes a function in terms of its value on smaller inputs

A statistical method to forecast future values

A function that always returns constant time

2.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following is a divide-and-conquer recurrence form?

T(n) = T(n-1) + 1

T(n) = n + 1

T(n) = aT(n/b) + f(n)

T(n) = T(n-2) + T(n-1)

3.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is the first step in solving a recurrence using the substitution method?

Apply the Master Theorem

Guess the form of the solution

Draw the recursion tree

Solve the base case

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

In solving T(n) = 2T(n/2) + n by substitution, what is a reasonable guess for the solution?

O(n)

O(n^2)

O(n log n)

O(log n)

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What does the recursion tree method primarily help you identify?

The exact runtime of any algorithm

The flowchart of an algorithm

The cost at each level and total cost across recursive levels

The loop structure in recursive calls

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

For the recurrence T(n) = 2T(n/2) + n, what is the cost at each level of the recursion tree?

Halved each level

Constant at each level

Increases exponentially

Remains n at each level

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

In the Master Theorem, what does the function f(n) represent?

The number of recursive calls

The input size

The cost of dividing and combining work

The base case value

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?