
算法
qq373432361
这个作者很懒,什么都没留下…
展开
-
LeetCode
Find Minimum in Rotated Sorted Array Suppose a sorted array is rotated at some pivot unknown to you beforehand.(i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2).Find the minimum element原创 2014-10-16 14:17:15 · 478 阅读 · 0 评论 -
LeetCode-Reverse Words in a String
Given an input string, reverse the string word by word.For example,Given s = "the sky is blue",return "blue is sky the".click to show clarification.Clarification:What constitutes原创 2014-10-19 18:43:31 · 513 阅读 · 0 评论 -
LeetCode-Maximum Product Subarray
Maximum Product Subarray Find the contiguous subarray within an array (containing at least one number) which has the largest product.For example, given the array [2,3,-2,4],the contig原创 2014-10-19 17:41:58 · 517 阅读 · 0 评论 -
LeetCode - Max Points on a Line
Max Points on a LineGiven n points on a 2D plane, find the maximum number of points that lie on the same straight line.原创 2014-10-21 14:10:16 · 467 阅读 · 0 评论 -
正则表达式
正则表达式有多种不同的风格。下表是在PCRE中元字符及其在正则表达式上下文中的行为的一个完整列表:字符描述/将下一个字符标记为一个特殊字符、或一个原义字符、或一个向后引用、或一个八进制转义符。例如,“n”匹配字符“n”。“/n”匹配一个换行符。串行“//”匹配“/”而“/(”则匹配“(”。^匹配输入字符串的开始位置。如果设置了RegExp对象的M转载 2015-03-04 13:39:13 · 1730 阅读 · 0 评论