Prizeout interview question

Object oriented programming design problem