摘要:
Write a function to find the longest common prefix string amongst an array of strings. 思路: 这道题其实很简单,但是比较别扭的是这道题不是一般情况下的按层来遍历,而是按列来遍历。可以考虑用第一个string做外层 阅读全文
摘要:
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 阅读全文