摘要: 题目描述 Given a linked list, remove the nth node from the end of list and return its head. For example, Given linked list: 1->2->3->4->5, and n = 2. Afte 阅读全文
posted @ 2017-05-30 10:22 qqky 阅读(143) 评论(0) 推荐(0) 编辑
摘要: 题目描述 Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity. 解题思路:借鉴于合并两个排序链表的题,采用分治法来解决该问题 不停的对半划分,比如k个链表先 阅读全文
posted @ 2017-05-30 09:52 qqky 阅读(200) 评论(0) 推荐(0) 编辑