[20250913] BOJ / G4 / 팀 빌딩 / 이강현 #880
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/22945
🧭 풀이 시간
30분
👀 체감 난이도
✏️ 문제 설명
개발자가 팀 빌딩을 함. 팀은 2명의 개발자가 모여야 하는데 이때 팀의 능력은 두 개발자 사이의 인원 수 x 두 개발자중 능력이 낮은 값임. 이때 최대가 되는 팀의 능력을 구하기.
🔍 풀이 방법
투 포인터
양 끝에 포인터를 두고 두 포인터 값들의 비교를 통해 더 작은 놈을 옮기면서 최댓값을 찾기
⏳ 회고
애초에 대놓고 투 포인터로 준건데 이렇게 문제로 만드니까 헷갈렸음.
두 개발자 사이의 개발자 수라는 것으로 포인터를 줄여가며 최댓값을 찾으라는 의도