#Given a zip code route the mail to the correct post office. #Zip codes 90000 or above go to Post Office A #Zip codes between 80000 to 89999 go to Post office B #All other packages go to Post Office C zip_code = 10210 if (zip_code >= 90000): print("Route package to Post Office A") elif (zip_code <= 89999 and zip_code >= 80000): print("Route package to Post Office B") else: print("Route package to Post Office C")
Run
Reset
Share
Import
Link
Embed
Language▼
English
中文
Python Fiddle
Python Cloud IDE
Follow @python_fiddle
Browser Version Not Supported
Due to Python Fiddle's reliance on advanced JavaScript techniques, older browsers might have problems running it correctly. Please download the latest version of your favourite browser.
Chrome 10+
Firefox 4+
Safari 5+
IE 10+
Let me try anyway!
url:
Go
Python Snippet
Stackoverflow Question