3 Sum - LeetCode
Dec 11, 2021 · 2 min read · The problem is taken from 15. 3Sum. Naive Approach Naive approach would be to go through all possible triplets in the array. And use set data structure to remove duplicates. Code - class Solution { public: vector<vector<int>> threeSum(vector<i...
Join discussion



