Question d’entretien chez Google

Merge k sorted int arrays, each array containing n ints, into 1 array. And give the complexity.

Réponses aux questions d'entretien

Utilisateur anonyme

13 juil. 2012

K way merge with heap is a solution. The time complexity is nklog(k)

1

Utilisateur anonyme

5 juil. 2012

Loser Tree is a solution. The time complexity is O(n*k*log(k)).