% cut3.pl:  As long as we have this example set up, we might as well
% see what happens if we position the cut ahead of both existing goals
% (this example) and after both of them (the next example, cut4.pl).
%
% Here's the database with the cut first:

firstvalue(a).
firstvalue(b).
secondvalue(1).
secondvalue(2).

cartesian(X,Y) :- !, firstvalue(X), secondvalue(Y).

% Before reading further:  What do you think will happen, and why?
% Go ahead and try it, then read on.
%
%
%
% Surprised?  If you understood cut2.pl, most likely you were not.
% We know from cut2.pl that we can backtrack on predicates to the right
% of the cut.  Here, both are to the right of the cut, giving us the
% same result as cut1.pl.  We cannot backtrack through the cut, but we
% don't need to do so to produce the complete result.
