leetcode
sunsiemngkira
这个作者很懒,什么都没留下…
展开
-
leetcode JAVA Reverse Words in a String 难度系数2-3?最新题151
本来用了string的split,写完发现二了,没有办法切割多个空格的情况,如果想切割多个空格,那就一定要带上正则表达式了。于是老老实实的从尾遍历到头。好吧,上代码:Reverse Words in a StringGiven an input string, reverse the string word by word.For example,G转载 2014-03-30 11:38:19 · 676 阅读 · 0 评论 -
leetcode-Climbing Stairs
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 climb to the top?Easy solutions f转载 2014-04-03 13:42:01 · 458 阅读 · 0 评论 -
LeetCode Single Number I & II 都符合两个问题额外要求的 通用解法 与 思考过程
LeetCode Single Number I & II 都符合两个问题额外要求的 通用解法 与 思考过程2013-11-02 08:07:03 我来说两句 作者:靖心收藏 我要投稿Single NumberGiven an array of integers, every element appears twice except for转载 2014-04-03 13:04:51 · 727 阅读 · 0 评论 -
leetcode 难题 Unique Binary Search Trees
Unique Binary Search Trees Total Accepted: 11242 Total Submissions: 31688My SubmissionsGiven n, how many structurally unique BST's (binary search trees) that store values 1...n?For exa原创 2014-04-06 00:32:33 · 353 阅读 · 0 评论 -
leetcode-reverse words in a string
Reverse Words in a String Total Accepted: 6674 Total Submissions: 47976My SubmissionsGiven an input string, reverse the string word by word.For example,Given s = "the sky is blue",原创 2014-04-04 10:20:29 · 462 阅读 · 0 评论