The google kickstart 2020 round C problem which is question number 3 and named as perfect subarray.This problem is very important with programming interview perspective as well because it covers a very important concept which is required to solve many other problems as well.

Intuition :

There are two simple solutions for this problem.One by using array and another by using Map.I have shown the intuition and logic behind solving the problem.

I have explained each step clearly and have also taken proper examples to show the algorithm for both positive and negative cases.At the end of the video, i have shown the code walkthrough. Code is present below as usual. If you find any difficulty or have any query then do COMMENT below.

Tutorial :

Code :

Write a comment