Loading, please wait...

ADA Algorithm MCQ Quiz (Multiple Choice Questions And Answers)

Search here for MCQs

Are you preparing for the next job interviews? If yes, trust me this post will help you also we'll suggest you check out a big collection for Programming Full Forms that may help you in your interview:

List of Programming Full Forms 

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

  • Merge Sort
  • Bubble Sort
  • Quick Sort
  • Selection Sort

12. The minimum number of comparisons required to find the minimum and the maximum of 100 numbers is

  • 148
  • 146
  • 147
  • 100

13. The time complexity of an algorithm to compute M1 × M2 will be

Two matrices M1 and M2 are to be stored in arrays A and B respectively. Each array can be stored either in row-major or column-major order in contiguous memory locations.
  • best if A is in row-major, and B is in column- major order
  • best if both are in row-major order
  • best if both are in column-major order
  • independent of the storage scheme

14. Randomized quicksort is an extension of quicksort where the pivot is chosen randomly. What is the worst case complexity of sorting n numbers using randomized quicksort?

  • O(n^2)
  • O (n log n)
  • O(!n)
  • O (n)

15. An unordered list contains n distinct elements.

The number of comparisons to find an element in this list that is neither maximum nor minimum is
  • O(1)
  • O (n log n)
  • O(!n)
  • O (n)