It is likely that Greg is gray. It is impossible that Mary went to the hallway. We believe that John left the apple. It is almost certain that if 'Greg is gray and John left the apple' then Sandra took the milk. We doubt that if 'Mary went to the hallway' or 'Greg is gray' or both then Jessica is a sheep. Chances are about even that if either 'Greg is gray' or 'Mary went to the hallway' but not both then Bernhard is white.
There is a better than even chance that 'Sandra took the milk' or 'Bernhard is white' or both.
There is a better than even chance that 'Sandra took the milk' or 'Bernhard is white' or both.
There is almost no chance that 'Sandra took the milk' or 'Bernhard is white' or 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.7::factA.
  0.0::factB.
  0.75::factC.
  %hop1
  0.95::factX:-and(factA,factC).
  0.2::factY:-or(factB,factA).
  0.5::factZ:-xor(factA,factB).

  %hop2
  conclusion:-or(factX,factZ).

  query(conclusion).
  
'Sandra took the milk' or 'Bernhard is white' or both.