Practical book for an Ai AI lab book Perplexity Chatgpt Ai Codes ..... Q1. from collections import deque # ------------------------------- # Undirected Graph Representation # ------------------------------- graph = { 'A': ['B', 'C'], 'B': ['A', 'D', 'E'], 'C': ['A', 'F'], 'D': ['B'], 'E': ['B', 'F'], 'F': ['C', 'E'] } # ------------------------------- # Depth First Search (Recursive) # ------------------------------- def dfs_recursive(graph, node, visited=None): if visited is None: visited = set() visited.add(node) print(node, end=" ") for neighbour in graph[node]: if neighbour not in visited: dfs_recursive(graph, neighbour, visited) # ------------------------------- # Breadth First Search (Iterative) # ------------------------------- def bf...