摘要:
class Solution {public: ListNode *reverseKGroup(ListNode *head, int k) { // Start typing your C/C++ solution below // DO NOT write int main() function int n=k; int len=0; ListNode *p=head; if (head == NULL || head->next == NULL||knext; } if (n > len) return head; ... 阅读全文
posted @ 2013-06-30 22:15
代码改变未来
阅读(1069)
评论(0)
推荐(0)
摘要:
class Solution {public: ListNode *mergeKLists(vector &lists) { int n=lists.size(); if(n==0)return NULL; ListNode *head=new ListNode(INT_MIN); ListNode *ret=head; int min; bool finish; while(1) { finish=true; min... 阅读全文
posted @ 2013-06-30 20:45
代码改变未来
阅读(942)
评论(0)
推荐(0)
浙公网安备 33010602011771号