RBC interview question

behavior question