Search Header Logo

Data Structures Through C (C-21) (UNIT 3 & 4)

Authored by Battala Krishna

Computers

12th Grade

Used 3+ times

Data Structures Through C (C-21) (UNIT 3 & 4)
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

10 sec • 1 pt

What is the best time complexity of bubble sort (optimized)?

  • N^2

  • N logN

  • N

  • N(logN)^2

2.

MULTIPLE CHOICE QUESTION

10 sec • 1 pt

What is the worst case time complexity of insertion sort where position of the data to be inserted is calculated using binary search?

  • N

  • N*log(N)

  • N2

  • N*log(N)2

3.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Which sorting algorithm will take least time when all elements of input array are identical?

  • Insertion Sort

  • Bubble Sort

  • Merge Sort

  • Selection Sort

4.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

Which of the following sorting algorithms has the lowest worst-case complexity?

  • Bubble Sort

  • Quick Sort

  • Merge Sort

  • Selection Sort

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Consider an array of elements arr[5]= {5,4,3,2,1} , what are the steps of insertions done while doing insertion sort in the array.  

  • 4 5 3 2 1

    2 3 4 5 1

    3 4 5 2 1

    1 2 3 4 5

  • 5 4 3 1 2

    5 4 1 2 3

    5 1 2 3 4

    1 2 3 4 5

  • 4 3 2 1 5

    3 2 1 5 4

    2 1 5 4 3

    1 5 4 3 2

4 5 3 2 1

  • 3 4 5 2 1

    2 3 4 5 1

    1 2 3 4 5

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which is the correct order of the following algorithms with respect to their time Complexity in the best case ?

Merge sort > Quick sort >Insertion sort > selection sort

Merge sort > selection sort > quick sort > insertion sort

insertion sort < Quick sort < Merge sort < selection sort

Merge sort > Quick sort > selection sort > insertion sort

7.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

What is the best sorting algorithm to use for the elements in array are more than 1 million in general?

  • Merge sort.

  • Quick sort.

Bubble sort.

Insertion sort.

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?