- 注册
- 2005-09-21
- 消息
- 8,913
- 荣誉分数
- 460
- 声望点数
- 0
You are given
k lists, each one containing a sorted sequence of numbers.
Let n denote the total number of elements in all these lists.
Give an O(n log k)–time algorithm that merges these k lists into one sorted list.
Explain why the running time of your algorithm is O(n log k).
Let n denote the total number of elements in all these lists.
Give an O(n log k)–time algorithm that merges these k lists into one sorted list.
Explain why the running time of your algorithm is O(n log k).