re.match: match from the beginning of the string re.search: scan through the whole string to find a match dash '-' inside square '[]' means a range. p ...
分类:
编程语言 时间:
2016-07-02 22:44:00
阅读次数:
204
Fire Net Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Description Suppose that we have a square city with straight ...
分类:
Web程序 时间:
2016-07-02 18:48:17
阅读次数:
258
Given a 2D binary matrix filled with 0's and 1's, find the largest square containing all 1's and return its area. For example, given the following mat ...
分类:
编程语言 时间:
2016-07-02 15:49:17
阅读次数:
141
69. Sqrt(x) 69. Sqrt(x) Total Accepted: 99997 Total Submissions: 388728 Difficulty: Medium Implement int sqrt(int x). Compute and return the square ro ...
分类:
其他好文 时间:
2016-07-02 11:48:32
阅读次数:
115
题目连接 https://leetcode.com/problems/valid-perfect-square/ Valid Perfect Square Description Given a positive integer num, write a function which returns ...
分类:
其他好文 时间:
2016-06-30 22:58:22
阅读次数:
177
//找到以什么什么字符串开头的句子,返回yes或者no; [square.url hasPrefix:@"http:"]; //找到以什么什么字符结尾的句子,返回yes或者no; [square.url hasPrefix:@"mod:"] ...
分类:
其他好文 时间:
2016-06-29 20:33:51
阅读次数:
130
Valid Perfect Square
Total Accepted: 1976 Total
Submissions: 5317 Difficulty: Medium
Given a positive integer num, write a function which returns True if num is a perfect squ...
分类:
其他好文 时间:
2016-06-28 11:04:11
阅读次数:
163
题目描述: Given a positive integer num, write a function which returns True if num is a perfect square else False. 解题分析: 这种找数字的题一般都用类似与二分查找的算法。需要注意的是比较平方和 ...
分类:
其他好文 时间:
2016-06-28 00:38:07
阅读次数:
234
Given an integer n, generate a square matrix filled with elements from 1 to n2 in spiral order. For example,Given n = 3, You should return the followi ...
分类:
编程语言 时间:
2016-06-27 15:31:55
阅读次数:
129
Typical binary search.. but take care of data overflow if you are using C++ ...
分类:
其他好文 时间:
2016-06-27 12:03:52
阅读次数:
112