479,010 views
29 votes
29 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 ArtKorchagin
by
3.0k points

1 Answer

7 votes
7 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 Poliquin
by
2.6k points