| Hosted by CoCalc | Download
Kernel: Prolog (Calysto)
child(stephanie). child(thad). mother_child(trude, sally). father_child(tom, sally). father_child(tom, erica). father_child(mike, tom). sibling(X, Y) :- parent_child(Z, X), parent_child(Z, Y). parent_child(X, Y) :- father_child(X, Y). parent_child(X, Y) :- mother_child(X, Y).
Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database.
father_child(tom, sally)?
Use '%continue' for more results.
True
has(jack,apples). has(ann,plums). has(dan,money). fruit(apples). fruit(plums).
Rule added to database. Rule added to database. Rule added to database. Rule added to database. Rule added to database.
has(jack,_)? has(dan, money)?
Use '%continue' for more results. Use '%continue' for more results.
True
%continue
Use '%continue' for more results.
True
has(ann, money)?
No more results.