Question: Provide a Breadth First Search ( BFS ) starting at vertex C ( C like the first letter of Car ) . Pick nodes to

Provide a Breadth First Search (BFS) starting at vertex C (C like the first letter of Car). Pick nodes to visit
using alphabetical order (when multiple choices are possible). Do not confuse BFS with DFS.
2. Provide a Depth First Search (DFS) starting at vertex E (E like the first letter of Enter). Pick nodes to visit
using alphabetical order (when multiple choices are possible). Do not confuse BFS with DFS. Notice the
start vertex used for DFS is NOT the same one used for BFS.
3. Apply Dijkstras algorithm using B (like the first letter of Bob) as the starting (source) node. Indicate
the cost and predecessor for each node in the graph after processing three nodes (B and two additional
nodes). To provide your answers in the BfsDfsDijkstras.java file, use -1(negative one) to represent
infinity and "-"(dash, not underscore) to represent no predecessor. In the BfsDfsDijkstras.java file, we
have used the value -9 for costs and "*" for predecessors, so the code compiles, but you must update cost
entries to a cost or -1(negative one) and predecessor entries to a predecessor or "-". If you leave the -9
and the "*" in your tables, they will be considered wrong.
Tables are given on the next page.
2

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!