- 博客(3)
- 资源 (1)
- 收藏
- 关注
原创 Lintcode Stack 423 Valid Parentheses
Java VersionString.valueOf(c) 方法是把c转化成String类型思路是将String中的({[中其中一个push进stack中,譬如(,如果stack非空并且下一个c是),那么将(推出stack,依此类推,最后如果stack是空,则为有效的括号对。public class Solution {/** * @param s A strin
2017-06-16 08:34:40 188
原创 Lintcode LinkedList 113 Remove Duplicates from Sorted List II
Java Version不能只写while (node.next.next!=null) 否则下述情况不成立,因为node为2,2的next为null就要终止0->1->2->3->3->4->4->null不能单单考虑下述情况0->1->2->3->3->3->4->null不同于 Lintcode 112 Remove Duplicates from Sorted Li
2017-06-15 17:46:22 190
原创 Lintcode LinkedList 174 Remove Nth Node From End of List
Given a linked list, remove the nth node from the end of list and return its head.ExampleGiven linked list: 1->2->3->4->5->null, and n = 2.After removing the second node from the end, th
2017-06-12 14:51:36 178
Compution vision stevens ppt
2018-02-24
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人