[20250614] BOJ / G3 / 순회강연 / 김수연 #355
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/2109
🧭 풀이 시간
25분
👀 체감 난이도
✏️ 문제 설명
각 대학에서 학자에게 d일 안에 와서 강연을 해주면 p만큼의 강의료를 지불한다.
하루에 최대 한 곳에서만 강연을 할 수 있을 때, 최대로 벌 수 있는 돈 구하기
🔍 풀이 방법
강의료 기준으로 내림차순으로 정렬하고,
최대 가능 날짜의 역순으로 내려오면서 강의가 가능한 날짜 찾아서 저장
⏳ 회고
할만했다