We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents f7de04d + f1a28f7 commit 8188ea6Copy full SHA for 8188ea6
arrays_and_strings/three_sum/three_sum.py
@@ -34,7 +34,7 @@ def three_sum(nums: List[int]) -> List[List[int]]:
34
35
# If the sum is zero, append the triplet to the result and skip duplicates
36
if current_sum == 0:
37
- triplets.append([nums[i], nums[low], nums[high]])
+ triplets.append(([nums[i], nums[low], nums[high]))
38
# Skip duplicates of the low pointer to avoid redundant triplets
39
while low < high and nums[low] == nums[low + 1]:
40
low += 1
0 commit comments