dis(or(B1,B2)) :- con(B1),dis(B2). dis(B) :- con(B). con(and(B1,B2)) :- dis(B1),con(B2). con(B) :- bool(B). bool(0). bool(1).