correcting the loop for creating the map