AI - LAB Midterm Fall-2020 Updated Paper

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

Mid-Term Exam (Take-Home) Fall - 2020

Subject: Artificial Intelligence LAB Submission Day:


Instructor:Hira Farman, Darakshan syed, Sophia ajaz, Safdar Hussain
Submission Date:
Program: Max. Marks: 20

Faculty of Engineering Science and Technology

Please follow the instructions carefully:


1. Write your answers in a Word file and upload the file before the due date on BlackBoard.
(Attach screen shots of the implementation make sure picture size is not large)

2. Write your name and registration ID on the first page of your Word file.

3. Answer scripts can be uploaded on BlackBoard any time before its deadline.
Therefore, do not wait for the last hour to avoid any unforeseen problems.

4. Submission of answer copy(ies) will be considered acceptable through BlackBoard


only. Therefore, do not submit your document through email or any other medium.

5. Use 12 pt. font size and Times New Roman font style along with 1-inch page margins.

6. Follow the requirements of the word limit and the marking criteria while writing your
answers.

7. Provide relevant, original and conceptual answers, as this exam aims to test your ability to
examine, explain, modify or develop concepts discussed in class.

8. Do not copy answers from the internet or other sources. The plagiarism of your answers
may be checked through Turnitin.

9. Recheck your answers before the submission on BlackBoard to correct any content or
language related errors.

10. Double check your word file before uploading it on BlackBoard to ensure that you have
uploaded the correct file with your answers.
Question1:[marks:10]

As you get close to graduating MIT, you decide to do some career planning. You create a graph of your
options where the start node is M = MIT and your goal node is R = Retire, with a bunch of options in
between. Your graph includes edge distances that represent, roughly, the “cost of transition” between
these careers (don't think too hard about what this means). You also have heuristic node-to-goal
distances which represent your preconceptions about how many more years you have to work until you
retire. For example, you think it will take 25 years to go from MIT (M) to retirement (R), 30 years from
Grad School (B), but only 2 years from Entrepreneur (E).

A = Wall Street | B = Grad School | C = Professor | D = Government | E = Entrepreneur

In all search problems, use alphabetical order to break ties when deciding the priority to use for
extending nodes.

Assume you want to retire after doing the least number of different jobs. Of all the
basic search algorithms you learned about(that is, excluding branch and bound and
A*) which one should you apply to the graph in order to find a path, with the least
search effort, that has the minimum. Implement this scenario with any( uninformed
or informed search technique)
Question 2: [ marks:5]

Consider an agent that controls the traffic lights at a 4-way intersection (where 2 roads cross,
with traffic flowing in all directions). The lights have green/yellow/red main lights plus a left-
turn arrow and a pedestrian indicator. The agent controls which lights go on and how long they
stay on. Assume the intersection has signals for pedestrians and in-pavement detectors right
before the crosswalk for cars and bikes.
PEAS Description:
• Performance: answers could include safety (number of accidents at the intersection) and
minimizing average wait time (e.g. per car, bike, pedestrian)
• Environment: roads, cars, pedestrians, etc.
• Actuators: the traffic lights: green/yellow/red/arrow/walk/don’t-walk in each of the 4
directions
• Sensors: in-pavement traffic detectors (bike and car), pedestrian signal buttons
Design Rule based rational agent for the implementation of the given scenario

Question 3: [ marks:5]

Moving out of your apartment


After having successfully completed the AI course, you get a job in another town (as an AI
expert of course), and you have to move out of your apartment. You have already packed all
your belongings in nine moving boxes, scattered around the apartment, now all you have left to
do is to move these boxes into the moving truck, which is parked just outside of the apartment.
The boxes are too big to carry, so you have to push them between the rooms. The following graph
shows the four rooms in the apartment, the truck, how many boxes are initially in which rooms,
and how the rooms are connected:

bedroom livingroom
3 boxes 2 boxes

kitchen hall truck


3 boxes 1 box
🚶 no boxes

On each turn, you can either move or push a box into an adjacent location, in any direction:
north, south, east, west. When this story begins, you have just parked the truck.

Implement the given scenario & Formulate this problem as a search problem, i.e.:
 Design suitable representation of the search states?
 Design a method of initial state
 Set goal state
 Calculate path cost at each step.

You might also like