Ovarro interview question

a technique question about optimisation