摘要:
https://oj.leetcode.com/problems/search-for-a-range/就是一个二分查找,没事练练手 1 public class Solution { 2 public int[] searchRange(int[] A, int target) { 3 ... 阅读全文
posted @ 2014-07-05 22:12
hansongjiang8
阅读(235)
评论(0)
推荐(0)
摘要:
这个问题,前面思考过,当时就是用搜索的方法,此处又遇到一次,发现自己理解的太浅了Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2.For example, Given: s1 = "aabcc",... 阅读全文
posted @ 2014-07-05 21:26
hansongjiang8
阅读(186)
评论(0)
推荐(0)
摘要:
参考:0开方 是 01的开方式 12的开方式 1.43.的开方=(1.4+3/1.4)/2牛顿迭代法:学习自http://blog.csdn.net/youwuwei2012/article/details/34075241public class Solution { public int ... 阅读全文
posted @ 2014-07-05 18:56
hansongjiang8
阅读(371)
评论(0)
推荐(0)
摘要:
1 public class Solution { 2 public void sortColors(int[] A) { 3 int len=A.length; 4 int beg=0; 5 int end=len-1; 6 ... 阅读全文
posted @ 2014-07-05 18:40
hansongjiang8
阅读(270)
评论(0)
推荐(0)

浙公网安备 33010602011771号