Loading problem…
You're building an analytics dashboard that displays maximum values in sliding time windows. For example, showing the maximum sales, page views, or user activity in each 5-minute window over the past hour.
You are given an array of integers nums, there is a sliding window of size k which is moving from the very left of the array to the very right. You can only see the k numbers in the window. Each time the sliding window moves right by one position.
Return the maximum value in each sliding window.