wet(water).
wet(milk).
wet(orange_juice).
cost(milk,95).
mother(betty,ann).
mother(delia,betty).
father(chris,ann).
father(eric,betty).
parent(X,Y) :- mother(X,Y).
parent(X,Y) :- father(X,Y).
next(dundee,arbroath).
next(arbroath,montrose).
next(montrose, stonehaven).
next(stonehaven,aberdeen).
before(X,Y) :- next(X,Y).
before(X,Y) :- before(X,W),next(W,Y).

