You are on page 1of 2

he Missionaries and Cannibals problem is a classic AI puzzle that can be defined as follows:

On one bank of a river are three missionaries and three cannibals.


There is one boat available that can hold up to two people and that
they would like to use to cross the river. If the cannibals ever
outnumber the missionaries on either of the rivers banks, the
missionaries will get eaten.
How can the boat be used to safely carry all the missionaries and
cannibals across the river?

the state for this problem can be defined as

{(i, j)/ i=0, 1, 2, 3, : j=0, 1, 2, 3}

where i represents the number missionaries in one side of a river . j represents the
number of cannibals in the same side of river. The initial state is (3,3), that is three
missionaries and three cannibals one side of a river , (Bank 1) and ( 0,0) on another side
of the river (bank 2) . the goal state is to get (3,3) at bank 2 and (0,0) at bank 1.

To sole this problem we will make the following assumptions:

1. Number of cannibals should lesser than the missionaries on either side.

2. Only one boat is available to travel.

3. Only one or maximum of two people can go in the boat at a time.

4. All the six have to cross the river from bank.

5. There is no restriction on the number of trips that can be made to reach of the goal.

6. Both the missionaries and cannibals can row the boat.

You might also like