In the video, they used vector to store the elements so the space complexity will be o(n)
but instead of that if we use map and store the count what’s the problem in that??
also the problem statement we use give ans in o(1) how it can be using vector of n size