For instance, the following screenshot shows an example of running the program:
PS C:\Users\bvo\OneDrive - Swinburne University\Teaching\2024\AI\Assignments\A1\Sol2> python \search.py \RobotNav-test.txt BFS
3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]
.\RobotNav-test.txt BFS
<Node (7, 0)> 34
['down', 'right', 'right', 'right', 'right', 'up', 'up', 'right', 'right', 'right']
PS C:\Users\bvo\OneDrive - Swinburne University\Teaching\2024\AI\Assignments\A1\So12>
(NOTE: If you use the implementation from aima-python, you'll see a different number_of_nodes from the
above example. My implementation is to ensure consistency across ALL search methods.)
When a goal cannot be reached, standard output needs to be in the following format:
filename method
No goal is reachable; number_of_nodes
For instance, the following screenshot shows an example of running the program on a test case in which the
goal is not reachable:
PS C:\Users\bvo\OneDrive - Swinburne University\Teaching\2024\AI\Assignments\A1\Sol2> python .\search.py .\n1.txt BFS
3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]
.\n1.txt BFS
No goal is reachable; 13
PS C:\Users\bvo\OneDrive - Swinburne University\Teaching\2024\AI\Assignments\A1\Sol2>