Aspire's Library

A Place for Latest Exam wise Questions, Videos, Previous Year Papers,
Study Stuff for MCA Examinations - NIMCET

Previous Year Question (PYQs)



Match List-I with List-II
 List-I List-II
 (Algorithm) (Recurrence relation)
(A).Binary Search(I).  $T(n)=T(n/2)+c$ (where c is a constant)
 (B).Merge Sort (II). $T(n)=2T(n/2)+\Theta(n)$
 (C). Quick sort (worst case partitioning) (III). $T(n)=T(n-1)+\Theta$ (n)
 (D). Linear Search (IV). $T(n)=T(n-1)+c$ (where c is a constant)
Choose the correct answer from the options given below:
1. . (A) (I), (B) (II), (C) - (III), (D) - (IV)
2.  (A) - (I), (B) - (III), (C) - (II), (D) - (IV)
3.  (A) - (I), (B) - (II), (C)-(IV), (D)-III 
4. (A) (III), (B) - (IV), (C) - (I), (D) - (II)





Solution

Binary Search → $T(n)=T(n/2)+c$ → (I)
- Merge Sort → $T(n)=2T(n/2)+\Theta(n)$ → (II)
- Quick Sort (worst case) → $T(n)=T(n-1)+\Theta(n)$ → (III)
- Linear Search → $T(n)=T(n-1)+c$ → (IV)

Correct Answer: Option (1)


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

Ask Your Question or Put Your Review.

loading...