You should get the user input in the loop.
Also, empty string is "", not " ". The latest being space, not empty string
Also, empty string is "", not " ". The latest being space, not empty string
add_animals =[] while True: user_input=input("Enter animals names:") if user_input: add_animals.append(user_input) else: break print(add_animals)