python for loop an integer is required