본문 바로가기
PS/내가 보려고 쓰는 풀이

BOJ 22595

by dicohy27 2022. 10. 1.

https://www.acmicpc.net/problem/22595

 

22595번: Sightseeing Tour

The first line contains the number of sightseeing area N (1 ≤ N ≤ 100). Next N lines describe the integer matrix C, where the j-th element of the i-th row of the input describes Ci,j (0 ≤ Ci,j ≤ 1, 000, 000). For each i, you can assume Ci,i is alwa

www.acmicpc.net

xhdtlsid2 가 풀이 알려줬다.

그냥 어떻게 지우던 항상 경로가 존재해서 비용 작은 것만 골라서 지우면 됨.

대충 귀납법으로 증명 가능한데 간단해서 생략.

'PS > 내가 보려고 쓰는 풀이' 카테고리의 다른 글

CF 1741E  (0) 2022.10.12
CF 1741D  (0) 2022.10.12
BOJ 24493  (0) 2022.10.02
CF 1733D2  (0) 2022.10.02
BOJ 23875  (0) 2022.10.01