You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This discussion was converted from issue #9 on September 15, 2026 10:57.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Problem link
https://leetcode.com/problems/sliding-window-maximum/
Problem Summary
k 크기의 슬라이딩 윈도우에서 가장 큰 값들을 출력하는 문제.
Solution
말 그대로 슬라이딩 윈도우로 쭉 돌려가면서 큰 값이 될 후보를 덱으로 관리해주면 된다.
현재 값보다 작은 값이 이전에 나왔다면 그 값은 앞으로 최대가 될 수 없기 때문에 쭉 빼주는 연산만 해주면 된다.
Source Code
All reactions