Example
parent(karen,greg).
parent(joseph,greg).
parent(karen,mark).
parent(joseph,mark).
female(karen).
mother(M,C) :- parent(M,C), female(M).
?-mother(karen,greg).
YES
?-mother(karen,X).
X = greg ;
X = mark
?-mother(karen,joseph).
NO
?-mother(joseph,karen).
NO
Previous slide
Next slide
Back to first slide
View graphic version