template
文章平均质量分 55
baladeer
CV菜鸟
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
148. Sort List 21. Merge Two Sorted Lists
很好的一个模板题,链表找中点(快慢指针)和merge。/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */clas原创 2018-01-08 14:00:26 · 144 阅读 · 0 评论 -
206. Reverse Linked List
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */class Solution {public: Li原创 2018-01-08 18:39:23 · 127 阅读 · 0 评论 -
143. Reorder List
Given a singly linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→…You must do this in-place without altering the nodes' values.For example,Given {1,2,3,4}, reorder it t原创 2018-01-09 21:20:47 · 120 阅读 · 0 评论
分享