Skip to content

[20251105] BOJ / G4 / 직사각형과 쿼리 / 한종욱#1320

Merged
ShinHeeEul merged 1 commit intomainfrom
Ukj0ng
Nov 5, 2025
Merged

[20251105] BOJ / G4 / 직사각형과 쿼리 / 한종욱#1320
ShinHeeEul merged 1 commit intomainfrom
Ukj0ng

Conversation

@Ukj0ng
Copy link
Contributor

@Ukj0ng Ukj0ng commented Nov 5, 2025

🧷 문제 링크

https://www.acmicpc.net/problem/14846

🧭 풀이 시간

60분

👀 체감 난이도

✏️ 문제 설명

(x1, y1), (x2, y2) 영역에 포함되어 있는 서로 다른 정수의 개수 출력

🔍 풀이 방법

각 셀의 정수의 개수를 누적합으로 저장하고, sum[x2][y2][i] - sum[x1-1][y2][i] - sum[x2][y1-1][i] + sum[x1-1][y1-1][i]로 계산

⏳ 회고

누적합 나한텐 어렵다.

@ShinHeeEul ShinHeeEul merged commit d580966 into main Nov 5, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants