CS FundamentalsVery hardGATE CS (PYQ pattern)
An undirected network has links (cost): A-C 3, A-E 2, A-F 3, B-C 2, B-E 2, B-G 2, C-D 5, D-E 1, D-G 3, E-G 4. Link-state routing at A computes shortest paths. How many distinct minimum-cost paths lead from A to G, and what is the minimum cost?
- A. 4 paths, cost 6
- B. 3 paths, cost 6
- C. 3 paths, cost 7
- D. 2 paths, cost 5
Correct answer: B. 3 paths, cost 6
Dijkstra from A with path counting (adding counts when an equal-cost relaxation is found) gives cost 6 and 3 minimum-cost paths.
More Computer Networks questions
- Router X has neighbours A, B, C at link costs 2, 5, 1. It receives distance vectors (to D1, D2, D3, D4): from A (4, 9, 3, 7), from B (1…
- Routers A and B are connected, and B is directly connected to network C (cost 1 each link; RIP, infinity = 16, no split horizon or poison…
- In link-state routing each router floods its LSA: the originator sends it on every link, and any router receiving it for the first time…
- A weighted undirected graph on nodes 0..5 has edges (u,v,w): (0,1,1), (1,2,2), (0,2,2), (2,3,3), (1,3,3), (3,4,1), (2,4,4), (4,5,2)…
- Routers form a 4 x 4 grid with coordinates (row, column), 0 to 3, and links between horizontal and vertical neighbours of equal cost. Two…
- A leaky bucket holds at most 5 packets and leaks (sends) 1 packet at the end of every tick. In ticks 1 to 8, packets arrive as 3, 4, 0, 5…