Barclays interview question

Object oriented programming questions and probability