Skip to content

Conversation

@oncsr
Copy link
Contributor

@oncsr oncsr commented Aug 4, 2025

🧷 문제 링크

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

🧭 풀이 시간

45분

👀 체감 난이도

✏️ 문제 설명

직선 y = ax + b를 좌표평면에 추가하면, 해당 직선으로 인해 나누어지는 두 반평면 중 (0, -INF)를 포함하는 반평면을 먹을 수 있다.
직선을 추가하는 작업과, 특정 x좌표에서의 먹은 영역 중 y좌표 최댓값을 구하는 작업이 총 Q회 주어지면 작업을 처리해보자.

🔍 풀이 방법

  • 볼록 껍질을 이용한 최적화

직선 관리를 효율적으로 하기 위해, 볼록 껍질을 이용한 최적화를 적용
구간 [-1e12, 1e12]에 대해 Li-Chao 트리로 특정 구간에서 최대가 되는 직선들을 관리한다.

⏳ 회고

오랜만에 해서 가물가물하다

@oncsr oncsr self-assigned this Aug 4, 2025
@oncsr oncsr added the success 👍 해설을 보지 않고 풀었을 때 label Aug 4, 2025
@ShinHeeEul ShinHeeEul merged commit 586f3af into main Aug 4, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

success 👍 해설을 보지 않고 풀었을 때

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants