Design and Analysis of Algorithms Quiz

Design and Analysis of Algorithms Quiz

12th Grade

14 Qs

quiz-placeholder

Similar activities

Heap

Heap

12th Grade

10 Qs

Quiz on Data Structure

Quiz on Data Structure

12th Grade

10 Qs

AP CSP Unit 10 Algorithms

AP CSP Unit 10 Algorithms

12th Grade

15 Qs

Time Complexity Quiz

Time Complexity Quiz

12th Grade

11 Qs

GCSE Computer Science 9-1: Sorting Algorithms

GCSE Computer Science 9-1: Sorting Algorithms

10th Grade - University

10 Qs

OCR A2 Computer Science Algorithms Quiz

OCR A2 Computer Science Algorithms Quiz

12th Grade

15 Qs

Sorting  Algorithms &  Efficiency

Sorting Algorithms & Efficiency

11th - 12th Grade

15 Qs

Algorithm and Problem Solving Quiz

Algorithm and Problem Solving Quiz

12th Grade

10 Qs

Design and Analysis of Algorithms Quiz

Design and Analysis of Algorithms Quiz

Assessment

Quiz

Computers

12th Grade

Hard

Created by

meghana pandita

Used 5+ times

FREE Resource

14 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does time complexity measure in an algorithm?

Number of lines of code

Number of operations executed

Amount of memory used

Input size

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following best describes space complexity?

The number of times an algorithm loops

The number of inputs an algorithm can handle

The amount of time an algorithm takes to run

The amount of memory an algorithm requires to execute

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the time complexity of a binary search algorithm?

O(1)

O(n)

O(log n)

O(n^2)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does Θ(n) represent in asymptotic notation?

Average-case time complexity

Best-case time complexity

Tight bound on the time complexity

Worst-case time complexity

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the solution to the recurrence relation T(n) = 2T(n/2) + n?

O(2^n)

O(n log n)

O(n)

O(n^2)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the time complexity of merge sort in all cases?

O(n^2)

O(n)

O(n log n)

O(log n)

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the worst-case time complexity of quick sort?

O(n^2)

O(n log n)

O(log n)

O(n)

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?