Question: proble Step 1) Create an undirected graph for the Word List shown in Figure 1. You need to use a Python dictionary (See 15 1.py)
proble Step 1) Create an undirected graph for the Word List shown in Figure 1. You need to use a Python dictionary (See 15 1.py) d. Ce Figure 1. Word List Step 2) Modify bfs() function in 15_ 1py to allow the user to enter 'startWord and 'endWord: The function should return 'True' if a transformation sequence exists. Return False if there is no such transformation sequence. Notice that you don't need to find the number of transformations. It searches the tree using BFS algorithm to see if a transformation sequence exists Submit hw11.py to Canvas Sample rurn C:lUsers\test\Desktop>hw11.py enter startword: hot enter endtWord : dog True C:\Users\test\Desktop>hwl1.py enter startWord: hot enter endtWord: cog True C:\UsersitestlDesktop>hwl1.py enter startWord : hit enter endtWord : ddd False
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
