Barclays Interview Question

Probability question