why did we reserve the first index of array?
Heap insertion- //ignore this
Hey @vashishthkuntal.gajjar2019 reserve is used to store minimum capacity.
You can see it’s documentation here->link
Example is well explained it will clear your doubt.
ya i saw the same docs but why to do v.push_back(-1)?