Data Structures & Algorithms Quiz

Data Structures & Algorithms Quiz

Professional Development

30 Qs

quiz-placeholder

Similar activities

TEKA LAGU TIRAM

TEKA LAGU TIRAM

Professional Development

25 Qs

EVALUACIÓN: CIENCIAS III QUÍMICA TERCER TRIMESTRE 2020-2021

EVALUACIÓN: CIENCIAS III QUÍMICA TERCER TRIMESTRE 2020-2021

1st Grade - Professional Development

25 Qs

Penaakulan Logik

Penaakulan Logik

KG - Professional Development

25 Qs

TEST Nº 02 RITE

TEST Nº 02 RITE

Professional Development

25 Qs

Ulangan Harian 2 Teks Pidato Persuasif

Ulangan Harian 2 Teks Pidato Persuasif

9th Grade - Professional Development

25 Qs

GROAP 14 - 2022

GROAP 14 - 2022

Professional Development

35 Qs

Kuis Sejarah Kemerdekaan & Pengetahuan Umum Prosa

Kuis Sejarah Kemerdekaan & Pengetahuan Umum Prosa

Professional Development

25 Qs

Comunicación Correos

Comunicación Correos

Professional Development

25 Qs

Data Structures & Algorithms Quiz

Data Structures & Algorithms Quiz

Assessment

Quiz

Other

Professional Development

Practice Problem

Hard

Created by

Niveditha Kani

Used 1+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

30 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Given an array sorted in non-decreasing order, what’s the best time to check if a number exists?

O(n)

O(log n)

O(n log n)

O(1)

2.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

To remove duplicates from a sorted array in-place, which two-pointer approach is used?

Fast slower pointers

Merge sort

Hashing

Backtracking

3.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Time complexity to reverse a string of length n?

O(1)

O(log n)

O(n)

O(n²)

4.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

For checking if one string is an anagram of another (both length n), best approach?

Bubble sort + compare (O(n²))

Hash map count (O(n))

Binary search

Merge sort + compare

5.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

What’s the time to find the longest prefix common to n strings (each of avg length m)?

O(n + m)

O(n × m)

O(log(nm))

O(n m log m)

6.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Removing the n-th node from the end can be done in:

O(n²)

O(n log n)

O(n) using two pointers

O(log n)

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

To detect a cycle in a linked list, which algorithm is used?

Hashmap

Sorting

Floyd’s cycle-finding

Backtracking

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?