Sliding Window Maximum
HardGiven an array and window size k, print the maximum value in each contiguous window of length k.
Input format:
- First line: n k
- Second line: n integers
Print the window maximums on one line.
Constraints
1 <= k <= n <= 10^5 -10^9 <= nums[i] <= 10^9