in Algorithms edited by
2,414 views
1 vote
1 vote

Given two sorted list of size $m$ and $n$ respectively. The number of comparisons needed the worst case by the merge sort algorithm will be:

  1. $m \times n$
  2. maximum of $m$ and $n$
  3. minimum of $m$ and $n$
  4. $m+n-1$
in Algorithms edited by
by
2.4k views

1 Answer

3 votes
3 votes
Best answer

option d

worst case comparisons in merge sort is o(m+n-1)

selected by

4 Comments

How many for best case ??
1
1
min(m,n)
0
0
It depends , either max(m,n) or min(m,n) . Out of these two cases , one of the answer is possible and which one is to choose out of these two is completely depends on particular arrays .
0
0
Answer:

Related questions