Median is the middle value in an ordered integer list. If the size of the list is even, there is no middle value. So the median is the mean of the tw...
A city’s skyline is the outer contour of the silhouette formed by all the buildings in that city when viewed from a distance. Now suppose you are giv...
Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity.解法一：用heap来做，先把k个list的第一个元素放进heap，每次poll出一个后，放进poll出...