3Sum – Leetcode 15 – Javascript
Here I implement and explain both the optimal solution and brute force solution, since the brute force solution can often help us develop intuition and deeper understanding of the optimal solution. 3sum a popular interview question that can be a follow up question to two sum.
Two sum on a sorted array: https://www.youtube.com/watch?v=9r63o60zBRg
Chapters:
00:00 Intro
00:47 Brute Force Solution
05:28 Optimal Solution
#javascript #algorithms #leetcode #codinginterview
Comments are closed.