0% found this document useful (0 votes)
41 views2 pages

Programming Assignment 1

This document provides instructions for Programming Assignment 1 on artificial intelligence at Makerere University. Students are asked to implement and compare different search algorithms (depth-first search, breadth-first search, uniform cost search, greedy search, A*) on a given graph. The tasks involve reading about the search strategies, representing the graph from Figure 1 in Python, implementing the searches for both tree and graph problems, and printing the results of each search including state expansion order and uncovered states.

Uploaded by

tashatakia3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views2 pages

Programming Assignment 1

This document provides instructions for Programming Assignment 1 on artificial intelligence at Makerere University. Students are asked to implement and compare different search algorithms (depth-first search, breadth-first search, uniform cost search, greedy search, A*) on a given graph. The tasks involve reading about the search strategies, representing the graph from Figure 1 in Python, implementing the searches for both tree and graph problems, and printing the results of each search including state expansion order and uncovered states.

Uploaded by

tashatakia3
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

MAKERERE UNIVERSITY

COLLEGE OF COMPUTING AND INFORMATION SCIENCE


DEPARTMENT OF COMPUTER SCIENCE
ACADEMIC YEAR 2023/2024
CSC 2114: ARTIFICIAL INTELLIGENCE
PROGRAMMING ASSIGNMENT 1: Problem solving using search
Due Date: 2nd October 2023
Instruction
This assignment is to be done on individual basis but you are free to make consultations
Assignment1 goal. To enable student understand the difference between different search
algorithms, their way of operation and implementation
Problem description: You will investigate various search algorithms for the graph in Figure 1.
Edges are labeled with their costs, and heuristic values h for states are labeled next to the
states. S is the start state, and G is the goal state.
Tasks to do
1. Read about the general operation of the following search strategies for both tree search
and graph search
a. Depth first search d. Greedy search
b. Breadth First Search e. A* search
c. Uniform cost search
f.
2. Using sets and dictionary libraries represent the graph in Figure 1 into a python graph
structure.
3. Using python implement the following search strategies using for tree search
a. Depth first search d. Greedy search
b. Breadth First Search e. A* search
c. Uniform cost search
4. Using python implement the following search strategies using for graph search
a. Depth first search d. Greedy search
b. Breadth First Search e. A* search
c. Uniform cost search
5. For each of the following graph search strategies, print out the order in which states are
expanded, the path returned by tree search, as well as the states that are not expanded.
In all search algorithms, assume ties are broken in alphabetical order.
a. Depth first search d. Greedy search
b. Breadth First Search e. A* search
c. Uniform cost search
6. For each of the following graph search strategies, print out the order in which states are
expanded, the path returned by graph search, as well as the states that are not
expanded. In all search algorithms, assume ties are broken in alphabetical order
a. Depth first search d. Greedy search
b. Breadth First Search e. A* search
c. Uniform cost search

Figure 1

You might also like