- 博客(4)
- 收藏
- 关注
原创 61
# Definition for singly-linked list.# class ListNode:# def __init__(self, x):# self.val = x# self.next = Noneclass Solution: def rotateRight(self, head: ListNode, k: int)...
2019-08-04 17:08:13 126
原创 lc56
class Solution { public int[][] merge(int[][] intervals) { // 数据长度未达到合并操作要求 if (intervals.length < 2) return intervals; //按二维数组第一位排序 Arrays.sort(inte...
2019-07-29 23:01:49 187
原创 MergeKlists
class Solution: def mergeKLists(self, lists: List[ListNode]) -> ListNode: a=[] for l in lists: h=l while h: a.append(h.val) ...
2019-07-29 21:33:21 273
原创 leetcode 24
递推法:class Solution: def swapPairs(self, head: ListNode) -> ListNode: p=ListNode(0) p.next=head t=p while t.next and t.next.next: i=t.next ...
2019-07-23 10:18:54 73
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人