Leetcode 23. Merge k Sorted Lists
3 solutions- Compare one by one & Heap &MergeSort
Solution 1- Compare one by one (slow)
class Solution {
public ListNode mergeKLists(ListNode[] lists) {
ListNode head=new ListNode(...
原创
2018-11-16 06:20:21 ·
153 阅读 ·
0 评论