Define the step - Rearranging the Execution Order for Efficiency
As we know that algorithm and data structure are closely related to one another, but data structure is considered as the smallest but very significant part of algorithm. Hence, after optimizing data structure, we try to optimize algorithm itself.
In general, algorithm optimization can be achieved by removing dead paths as fast as possible. For this, we sometimes reverse execution order of the loop from original functional model.