摘要: #include #include using namespace std; ///Definition for singly-linked list. struct ListNode { int val; ListNode *next; ListNode(int x) : val(x), next(NULL) {} }; /// LinkedList Test... 阅读全文
posted @ 2017-07-01 22:00 czcColud 阅读(125) 评论(0) 推荐(0) 编辑
摘要: class Solution { public: ListNode *reverseKGroup(ListNode *head, int k) { if (!head || !(head->next) || k next; else return head; // rev... 阅读全文
posted @ 2017-07-01 19:25 czcColud 阅读(249) 评论(0) 推荐(0) 编辑