[20250820] BOJ / G4 / 가운데에서 만나기 / 한종욱 #697
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/21940
🧭 풀이 시간
60분
👀 체감 난이도
✏️ 문제 설명
준형이와 친구들의 왕복시간 들 중 최대가 최소가 되는 시간 X를 선택한다. 해당 도시가 여러 개인 경우 도시의 번호를 오름차순으로 출력한다.
🔍 풀이 방법
다익스트라를 사용하는데, N = 200이고 각 도시마다 다익스트라를 사용한다면,$ElogV*E$ 이기 때문에 200x20x200으로 시간복잡도가 충분했다.
⏳ 회고
마지막 답을 결정할 때, 모든 도시가 아니라 준형이와 친구들의 도시만 고려해야 했는데 전부를 고려했다. 문제의 지시사항을 잘 읽어봐야겠다.