father(bill,jake). father(bill,shelley). father(james,peter). father(james,john). mother(mary,jake). mother(mary,shelley). mother(muriel,peter). mother(muriel,john).
Add a rule that will describe the sibling relationship, that is "has the same mother and father". Use the following left-hand-side of the rule:
where X and Y are the names of potential siblings.sibling(X,Y) <=
For the purposes of this problem we will permit sibling relationships to include a person being their own sibling!
Last updated 2002/03/13
© J.A.N. Lee, 2002.