Added more comments, and variation with for loop (not working)