Apple interview question

solve a riddle