Input/Output Issue
The input file represents the network. It should be formatted as a space-delimited file, where each line contains the start node, destination node, and an optional edge weight. The test network. It is undirected and unweighted. The input file for…