Maximum Element in every window of size k

my code is showing wrong answer.please correct it

I have made some minor changes in your code, but could not find the ques link on hackerblocks to submit the same. If you can provide me the link of this question on hackerblocks that would be every beneficial.

Even I cannot find it.It is the same code given in the video by sanket singh sir.then why its not working?
his all codes are not running properly on ide.Why?

well the code looks fine to me. maybe you can try submitting it on https://leetcode.com/problems/sliding-window-maximum/

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.