摘要:
Divide two integers without using multiplication, division and mod operator.If it is overflow, return MAX_INT.思路:尼玛,各种通不过,开始用纯减法,超时了。然后用递归,溢出了。再然后终于开窍... 阅读全文
posted @ 2015-02-06 22:09
匡子语
阅读(216)
评论(0)
推荐(0)
摘要:
Given an arraySofnintegers, are there elementsa,b,c, anddinSsuch thata+b+c+d= target? Find all unique quadruplets in the array which gives the sum of ... 阅读全文
posted @ 2015-02-06 14:40
匡子语
阅读(161)
评论(0)
推荐(0)
摘要:
Write a function to find the longest common prefix string amongst an array of strings.思路:找最长公共前缀 常规方法string longestCommonPrefix(vector &strs) { ... 阅读全文
posted @ 2015-02-06 13:37
匡子语
阅读(172)
评论(0)
推荐(0)

浙公网安备 33010602011771号