Move the loops into a function
Whitespace and dropped the create function