Info Edge Interview Question

Find first subarry whose sum equals k.

Interview Answer

Anonymous

Aug 17, 2022

First told the brute force O(n^2) approach, then optimised to O(n) using sliding window approach