摘要: Compare two version numbers version1 and version2.If version1 > version2 return 1, if version1 < version2 return -1, otherwise return 0. You may assum 阅读全文
posted @ 2016-05-08 10:24 Hygeia 阅读(137) 评论(0) 推荐(0) 编辑
摘要: Divide two integers without using multiplication, division and mod operator. If it is overflow, return MAX_INT. Subscribe to see which companies asked 阅读全文
posted @ 2016-05-08 09:29 Hygeia 阅读(157) 评论(0) 推荐(0) 编辑
摘要: Implement regular expression matching with support for '.' and '*'. 题目: 正则表达式的匹配,'.'能匹配任何一个字符,'*'之前必须有一个字符,两个结合起来表示之前那个字符出现0到无穷次。 解法: 一定要注意'*'必须结合前面的字 阅读全文
posted @ 2016-05-08 08:42 Hygeia 阅读(239) 评论(0) 推荐(0) 编辑
摘要: Given an array S of n integers, are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the array which gives the sum of 阅读全文
posted @ 2016-05-08 06:10 Hygeia 阅读(232) 评论(0) 推荐(0) 编辑