pos(a). pos(b). pos(c). pos(d). move(a,b). move(b,a). move(b,c). move(c,d). win(X) :- move(X,Y), not win(Y). lose(X) :- pos(X), not win(X).