Nagarro interview question

i was asked to optimize the solution I provided in coding round.

Interview Answer

Anonymous

17 May 2015

i optimized it by taking few steps out of the loop and restructuring code.