...
Algorithms
January 3, 2025
Process-Scheduling
January 4, 2025
Algorithms
January 3, 2025
Process-Scheduling
January 4, 2025

Algorithms

Question 43

Give the correct matching for the following pairs:

            A. O(log n)     1. Selection sort
            B. O(n)         2. Insertion sort
            C. O(nlog n)    3. Binary search
            D. O(n2)        4. Merge sort   
A
A – R B – P C – Q D – S
B
A – R B – P C – S D – Q
C
A – P B – R C – S D – Q
D
A – P B – S C – R D – Q
Question 43 Explanation: 
Binary search = O(log n)
Selection = O(n)
Merge sort = O(n log n)
Insertion sort = O(n2)
Correct Answer: B
Question 43 Explanation: 
Binary search = O(log n)
Selection = O(n)
Merge sort = O(n log n)
Insertion sort = O(n2)

Leave a Reply

Your email address will not be published. Required fields are marked *