Maximum of all Subarray of Size k

https://practice.geeksforgeeks.org/problems/maximum-of-all-subarrays-of-size-k/0

TLE

Hi Monika,
try using sliding window technique
consider two loops outer loop creates a window(actually a subarray)
and in the inner loop find the maximum for that window.
for further explanation refer to prateek bhaiya’s sliding window video lecture.

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.