Write a program that implements both distance vector routing or link state routing using Djikstra's algorithm.
The input to the program will be a file of nodes and links. The format of
the file will be such that each line will start with the name of a node,
followed by the name of another node and the cost of using that link. For
example, if node A is connected to nodes B, C, and D, and node B is connected to
A, D, and F, the entries in the file
will look like:
A B 1 C 2 D 4
B A 1 D 4 F 2
Your program should ask me for the file name and then ask what kind of routing I would like the network to use. Once the routing tables have been calculated, your program should allow me to see the routing table for any node(s) I want.
For Distance Vector routing, presume that each link has a distance of 1
For Link State Routing, use Djikstra's algorithm.
For extra credit, treat non-reciprocal links as one-way links for the purpose of routing. For example, if the entry for node A contains a link to B (as above), but the entry for node B does NOT contain a link to node A, this would mean that A can send to B, but B can NOT send to A. If your program can show how this would affect routing, you can get extra credit.