It is improbable that John picked up the apple. It is probably not the case that Lily is gray. It is improbable that Mary went to the office. We doubt that if 'Lily is gray and John picked up the apple' then Gertrude is a cat. It is probably the case that if 'John picked up the apple' or 'Mary went to the office' or both then Brian is a lion. It is highly likely that if either 'Lily is gray' or 'Mary went to the office' but not both then Bernhard is a swan.
It is likely that either 'Mary went to the office' or 'Lily is gray' but not both.
It is probably not the case that either 'Mary went to the office' or 'Lily is gray' but not both.
It is likely that either 'Mary went to the office' or 'Lily is gray' but not both.

  and(A,B) :- A,B.
  or(A,B) :- A;B.
  nand(A,B) :- not(and(A,B)).
  nor(A,B) :- not(or(A,B)).
  xor(A,B) :- or(A,B), nand(A,B).

  %hop0
  0.1::factA.
  0.25::factB.
  0.1::factC.
  %hop1
  0.2::factX:-and(factB,factA).
  0.7::factY:-or(factA,factC).
  0.9::factZ:-xor(factB,factC).

  %hop2
  conclusion:-xor(factC,factB).

  query(conclusion).
  
Either 'Mary went to the office' or 'Lily is gray' but not both.