fork download
  1. edge(a,c).
  2. edge(a,d).
  3. edge(a,e).
  4. edge(b,e).
  5. edge(b,c).
  6. edge(c,d).
  7. reach(X,Y) :- edge(X,Y).
  8. reach(X,Y) :-
  9. edge(X,Z),
  10. reach(Z,Y).
  11. sibling(X,Y) :-
  12. edge(Z,X),
  13. edge(Z,Y),
  14. X \== Y.
Success #stdin #stdout 0.02s 68352KB
stdin
Standard input is empty
stdout
GNU Prolog 1.3.1
By Daniel Diaz
Copyright (C) 1999-2009 Daniel Diaz