Optimization-2

8. Suboptimal pieces of code