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 zero.
Note: The solution set must not contain duplicate triplets.
解法1: Backtracking
典型的backtracking + 去重的问题。
主要的容易错的地方是怎么去重,当确定了其中一个数字的位置i之后,在变动left和right时,每当找到一个满足条件的解都要跳过之后所有和left或者right指向的相同的数字。