Question: Python: Graph Traversal Algorithm ExampleGraph.Py : https://pastebin.com/AiYj52Pe GraphExample.py : https://pastebin.com/AiYj52Pe 2. (30 points) Consider the following spider-web graph that shows a spider siting at the
Python: Graph Traversal Algorithm
ExampleGraph.Py : https://pastebin.com/AiYj52Pe

GraphExample.py : https://pastebin.com/AiYj52Pe
2. (30 points) Consider the following spider-web graph that shows a spider siting at the bottom of its web, and a fly sitting at the top. On moodle, there is a file called graphExample.py that implements the graph using a library called NetworkX 0 (a) Write an algorithm to determine how many different ways can the spider reach the fly by moving along the web's lines in the directions indicated by the arrows? (b) Implement your algorithm in Python using the NetworkX graph provided as your data structure. You may need to install NetworkX if it isn't part of your Python installation. Do not use any of the NetworkX features that would make this prob- lem trivial as part of your solution. However, you can use anything in NetworkX to verify your solution. Your algorithm should return an answer to the question in part (a 2. (30 points) Consider the following spider-web graph that shows a spider siting at the bottom of its web, and a fly sitting at the top. On moodle, there is a file called graphExample.py that implements the graph using a library called NetworkX 0 (a) Write an algorithm to determine how many different ways can the spider reach the fly by moving along the web's lines in the directions indicated by the arrows? (b) Implement your algorithm in Python using the NetworkX graph provided as your data structure. You may need to install NetworkX if it isn't part of your Python installation. Do not use any of the NetworkX features that would make this prob- lem trivial as part of your solution. However, you can use anything in NetworkX to verify your solution. Your algorithm should return an answer to the question in part (a
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
