[리트코드] 3620. Network Recovery Pathways
·
알고리즘연구소👨💻/혼자서는 세상을 구할 수 없다.
문제 내용과 입력You are given a directed acyclic graph of n nodes numbered from 0 to n − 1. This is represented by a 2D array edges of length m, where edges[i] = [ui, vi, costi] indicates a one‑way communication from node ui to node vi with a recovery cost of costi.Some nodes may be offline. You are given a boolean array online where online[i] = true means node i is online. Nodes 0 and n − 1 are always..