Important Project needed by May 8

1) Write a program that will implement a weighted graph and use Dijkstra’s Algorithm to calculate the shortest path from a start node to every other node in the graph. You may implement your graph using an edge list, adjacency list, or adjacency matrix structure. Your program must provide the user with a prompt to allow the user to construct the graph. The prompt should provide 6 commands: add_node, adde_edge, remove_edge, remove_node, Dijkstra, exit.

a. add_node <label> - Will add a node labeled with ‘label’ to the graph. A label will always be a character from a-z. If a node with that label already exists in the graph the program should not add a duplicate to the graph and should inform the user that a node with that label already exists.

b. add_edge <from> <to> <weight> - ‘From’ will be the label of the node that the edge starts from. ‘To’ will be the label of the node that the edge goes to. ‘Weight’ will be the be the numerical weight to assign to the edge. You should only all one edge from a given node to another node. If the user tried to add an edge that already exists print out a message informing them that that operation is not allowed.

c. remove_edge <from> <to> - Remove an edge from the graph that starts at ‘from’ and goes to ‘to’. If that edge does not exist then display a message to the user to indicate that the operation could not be completed

d. remove_node <label> - Remove a node from the list that is labeled with ‘label’ The node should not be able to be removed unless it has not edges going to or leaving from it. If the node does not exist or can not be removed display a message to tell the user why the operation could not be completed.

e. dijkstra <label> - Execute Dijkstra’s algorithm as discussed in class. ‘Label’ will be the label of the node to start from. If that node does not exist display a message to the user informing them that the operation could not be completed. Once Dijkstra’s algorithm has run you should display the nodes in the graph in order from closest to farthest starting from the source node.

Taidot: C++ -ohjelmointi

Tietoa työnantajasta:
( 0 arvostelua ) United States

Projektin tunnus: #16908280

Myönnetty käyttäjälle:

ali1997sta

Since i am a student of CS myself, i remember having being given such a project just recently and i am sure i will e able to serve excellently.

\$25 USD 1 päivässä
(1 arvostelu)
0.0

3 freelanceria on tarjonnut keskimäärin %project_bid_stats_avg_sub_26% %project_currencyDetails_sign_sub_27% tähän työhön

rixiang3

Hi, how are [login to view URL] to meet you. I have long experience with C++ programming. I am also have deep understanding Dijkstra’ algorithm. I am sure you are fully satisfied with me in this project. I hope your response.

\$25 USD 1 päivässä
(12 arvostelua)
3.1
\$25 USD 1 päivässä
(0 arvostelua)
0.0