Skip to content

Conversation

@oncsr
Copy link
Contributor

@oncsr oncsr commented Jul 23, 2025

🧷 문제 링크

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

🧭 풀이 시간

30분

👀 체감 난이도

✏️ 문제 설명

N개의 막대를 적절히 사용해서 만들어지는 직사각형들 중 그 넓이의 최댓값을 구해보자.

🔍 풀이 방법

  • 배낭 문제

직사각형에는 4개의 선분이 필요하다.
-> dp[a][b][c][d] = 각 막대의 길이가 a, b, c, d인 경우가 가능한가?

dp 테이블을 정의하기 위한 상한은 대략 s = (전체 막대의 합 / 2)라고 하면, s^4의 크기로(dp[s][s][s][s]) 잡으면 된다.

⏳ 회고

배고파요

@oncsr oncsr added the success 👍 해설을 보지 않고 풀었을 때 label Jul 23, 2025
@ShinHeeEul ShinHeeEul merged commit b57b5ad into main Jul 23, 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