
Rotate
文章平均质量分 54
所难
这个作者很懒,什么都没留下…
展开
-
LeetCode-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 to原创 2014-07-29 09:33:01 · 381 阅读 · 0 评论 -
LeetCode-Rotate List
Given a list, rotate the list to the right by k places, where k is non-negative.For example:Given 1->2->3->4->5->NULL and k = 2,return 4->5->1->2->3->NULL.Solution:Code:原创 2014-08-13 15:03:25 · 311 阅读 · 0 评论