Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

userHour= int(input('Enter hour (in 24 hour time): ')) if userHour = 12: print('Good Afternoon') elif userHour *Please check what's wrong with my code Write a

image text in transcribed

userHour= int(input('Enter hour (in 24 hour time): '))

if userHour = 12: print('Good Afternoon') elif userHour

*Please check what's wrong with my code

Write a program that asks the user for the hour of the day (in 24 hour time), and prints o "Good Morning" if it is strictly before 12, o "Good Afternoon" if it is 12 or greater, but strictly before 17, and o "Good Evening" otherwise. A sample run: Enter hour (in 24 hour time): 11 Good Morning Another sample run: Enter hour (in 24 hour time): 20 Good Evening And another run: Enter hour (in 24 hour time): 15 Good Afternoon

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

Describe three other types of visual aids.

Answered: 1 week ago