CIBC interview question

The first round was coding round on codility