## Assignment 2

Out: Friday, 8 February 2002
Due: Thursday, 14 February 2002 by 4:00pm
Extension: Wednesday, 20 February by 4:00pm

### Announcements

As previously announced, class and office hours on Tuesday, 12 February are cancelled. The class will be made up on Wednesday, 13 February from 11:30 to 12:20 in Olsen 414.

Office hours for the week of 11-15 February will be as follows:

• Wednesday, 13 February: 1:30 to 2:30.
• Thursday, 14 February: 1:00 to 3:00.

### Problem 1

Exercise 3.3 on p. 87-88 of Russell and Norvig.

### Problem 2

Exercise 3.4 on p. 88 of Russell and Norvig. You may choose to code this problem in C or Scheme. I'd recommend Scheme, since I think it's much easier to code this problem in Scheme. Start early on this, whichever language you choose.

Clarifications: Although the book describes the M&C problem in two ways (first is the "classic definition" stating that cannibals may not outnumber missionaries on either bank; second is the long, overly descriptive version that seems to suggest that missionaries should not outnumber cannibals either), you should code up the "classic" version. (You shouldn't be able to find a solution for the other version.) Cannibals may not outnumber missionaries. When the boat is on the shore, the people in the boat count as being part of the population on that shore.

### Problem 3

Exercise 3.5 on p. 88 of Russell and Norvig.

### Problem 4: For 91.543 students. EC for 91.420 students.

Problem 3.16, parts a, b, c, and e, on p. 90 of Russell and Norvig. Again, I'd recommend Scheme.

Clarification: Although part a states that you should write a goal test function that takes only the expression tree, it should also take the target sequence. Without the sequence, you have no way to test if the expression tree can generate a particular sequence.