上一页 1 ··· 7 8 9 10 11 12 13 14 15 下一页
摘要: You are climbing a stair case. It takes n steps to reach to the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you cl 阅读全文
posted @ 2016-04-14 13:45 新一代的天皇巨星 阅读(146) 评论(0) 推荐(0)
摘要: 121. Best Time to Buy and Sell Stock Say you have an array for which the ith element is the price of a given stock on day i. If you were only permitte 阅读全文
posted @ 2016-04-14 13:31 新一代的天皇巨星 阅读(305) 评论(0) 推荐(0)
摘要: Given a singly linked list, determine if it is a palindrome. Follow up:Could you do it in O(n) time and O(1) space? Linked List Two Pointers With extr 阅读全文
posted @ 2016-04-14 13:20 新一代的天皇巨星 阅读(239) 评论(0) 推荐(0)
摘要: Reverse a singly linked list. click to show more hints. Hint: A linked list can be reversed either iteratively or recursively. Could you implement bot 阅读全文
posted @ 2016-04-13 13:19 新一代的天皇巨星 阅读(112) 评论(0) 推荐(0)
摘要: 21. Merge Two Sorted Lists Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of th 阅读全文
posted @ 2016-04-12 13:15 新一代的天皇巨星 阅读(151) 评论(0) 推荐(0)
摘要: Code is everything: 阅读全文
posted @ 2016-04-10 05:45 新一代的天皇巨星 阅读(182) 评论(0) 推荐(0)
摘要: Given a binary tree, return all root-to-leaf paths. For example, given the following binary tree: 1 / \ 2 3 \ 5 All root-to-leaf paths are: ["1->2->5" 阅读全文
posted @ 2016-04-09 12:55 新一代的天皇巨星 阅读(160) 评论(0) 推荐(0)
摘要:   Subscribe to see which companies asked this question     阅读全文
posted @ 2016-03-14 08:16 新一代的天皇巨星 阅读(132) 评论(0) 推荐(0)
摘要: For example, this binary tree is symmetric:   But the following is not:   Note:Bonus points if you could solve it both recursively and iteratively. co 阅读全文
posted @ 2016-03-14 07:56 新一代的天皇巨星 阅读(129) 评论(0) 推荐(0)
摘要: Note:     Subscribe to see which companies asked this question     阅读全文
posted @ 2016-03-14 06:43 新一代的天皇巨星 阅读(417) 评论(0) 推荐(0)
上一页 1 ··· 7 8 9 10 11 12 13 14 15 下一页