AlgoMaster Logo

Number of Ways to Arrive at Destination

n=7,roads=[[0,6,7],[0,1,2],[1,2,3],[1,3,3],[6,3,3],[3,5,1],[6,5,1],[2,5,1],[0,4,5],[4,6,2]]
0 / 45
algomaster.io
Step:Count the shortest paths from node 0 to node 6