178k views
5 votes
Write a program that asks the user to enter a city name, and then prints Oh! CITY is a cool spot. Your program should repeat these steps until the user inputs Nope.

Write a program that asks the user to enter a city name, and then prints Oh! CITY-example-1
User Cristina
by
5.3k points

1 Answer

5 votes

Answer:

city = input("Please enter a city name: (Nope to end) ")

while city != "Nope":

print("Oh!", city, "is a cool spot.")

city = input("Please enter a city name: (Nope to end) ")

User Tom Harrison
by
5.5k points