Optimized code into single for loop