[20251121] BOJ / G5 / 빗물 / 강신지 #1466
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🧷 문제 링크
https://www.acmicpc.net/problem/14719
🧭 풀이 시간
30분
👀 체감 난이도
✏️ 문제 설명
w 너비에 대해 각 열마다 블럭의 높이가 주어짐. 블럭 사이에 고이는 물의 양 구하기.
🔍 풀이 방법
걍 구현.
각 열마다 해당 열 기준 좌측 열들의 최대 블럭 높이, 우측 열들의 최대 블럭 높이를 구하고 해당 열의 높이가 그들보다 작은지 판단하여 적절히 더해주기.
⏳ 회고
바닥은 막혀있다. 대충 읽고 풀다가 조건 고침