next up previous
Next: I/O Up: prolog Previous: Negation

Negation Examples

p(X) :- q(X), not(r(X)).
r(X) :- w(X), not(s(X)).
q(a). q(b). q(c).
s(a). s(c).
w(a). w(b).

Test for p(a).