yes :- ab(X), !, X=b.
yes.

ab(a).
ab(b).

% Cut zur Fallunterscheidung:

p :- q, !, r.
p :- s.

p :- if q then r else s.

% Prolog syntax:
p :- q -> r ; s.

% maximum relation:
%max(X,Y,M) :- X >= Y, M = X.
% max(X,Y,M) :- X < Y, M = Y.

%max(X,Y,M) :- X >= Y, !, M = X.
%max(X,Y,M) :- M = Y.

max(X,Y,M) :- X >= Y, !, M = X ; M = Y.



        