Treating probability as a logic, Thomas Bayes defined the following:
Pr(X|Y)=Pr(Y|X)Pr(X)/Pr(Y)
For example, probability that the weather was bad given that our friends played cricket can be calculated as:
Pr(play cricket in the rain)Pr(rain)/Pr(play cricket).