python-for-coding-test icon indicating copy to clipboard operation
python-for-coding-test copied to clipboard

P305 실전문제 '커리큘럼' 소스 관련 질문

Open camel-master opened this issue 4 years ago • 0 comments

큐가 empty 될 때까지 위상정렬을 수행하면서 리스트 result의 값을 업데이트 할 때 result[i] = max(result[i], result[now] + time[i] 와 같이 작성이 되어 있습니다.

예제의 경우 모든 노드의 가중치는 양수이므로 result[i] = result[now] + time[i] 과 같이 max 연산을 제거해도 문제가 없을지 궁금합니다.

camel-master avatar Jun 14 '21 23:06 camel-master