Finished adding converting for loops