You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
문제 링크
https://www.acmicpc.net/problem/3584
문제 조건
아이디어
처음에 풀이한 방법은 다음과 같다.
어찌저찌 풀긴 했으나 다른 사람들은 어떻게 풀었나 궁금해 검색해보니 좀 더 효율적인 방법이 있었다.
2, 3번 과정에서 나는 각 리스트로 경로를 저장한 뒤 비교했는데 그냥 방문 처리를 통해 제일 먼저 방문 처리된 노드를 발견하면 출력해주면 끝이다.
구현
All reactions