588 views
0 votes
0 votes

Consider n elements that are equally distributed in k stacks. In each stack, elements of it are arranged in ascending order (min is at the top in each of the stack and then increasing downwards). Given a queue of size n in which we have to put all n elements in increasing order. What will be the best algorithm and their time complexity?

I think Merge sort is best algorithm, O(n log logk)

 

Am I right or wrong?

 

 

Please log in or register to answer this question.

Related questions

0 votes
0 votes
0 answers
1
gateexplore asked Oct 25, 2023
131 views
It is always true that Recursive code is easier to debug?? If yes then why?? please give full explanation.
0 votes
0 votes
0 answers
4
Çșȇ ʛấẗẻ asked Mar 10, 2023
380 views
Determine the number of spanning tree in the following graph ?