I think a good way to remember the formula is to think of the formula like this:

The probability that some event A has a particular outcome given an independent event B’s outcome = the probability of both outcomes occurring simultaneously / whatever we’d say the probability of event A’s desired outcome would be if we didn’t know event B’s outcome.

As an example, consider a disease test: If we have a patient who tests positive for a disease, and we know that: 40% of diseased persons tested positive on our test; 60% of all people have this disease; and 26% of all people tested positive for this disease; then it follows that:

1) 24% of all people we sampled tested positive and had the disease, meaning 24 out of 26 people who tested positive had the disease; therefore,

2) there is a 92.3% chance that this particular patient has the disease.

**Answer**

It may help to recall that it follows from the definition of conditional probability:

p(a|b)=p(a,b)p(b)

p(a,b)=p(a|b)p(b)=p(b|a)p(a)

p(a|b)=p(b|a)p(a)p(b)

In other words, if you remember how joint probabilities factor into conditional ones, you can always derive Bayes rule, should it slip your mind.

**Attribution***Source : Link , Question Author : Community , Answer Author :
Sean Easter
*