Suppose we have k-sorted arrays each of length ‘n’. What is the running time to merge the k-sorted arrays to get a single array whose elements are sorted?
1
O(k)
2
O(n)
3
O(nk)
4
O(nklogk)
Suppose we have k-sorted arrays each of length ‘n’. What is the running time to merge the k-sorted arrays to get a single array whose elements are sorted?