摘要:
#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... 阅读全文
摘要:
class Solution { public: ListNode *reverseKGroup(ListNode *head, int k) { if (!head || !(head->next) || k next; else return head; // rev... 阅读全文