Question: Question 2 ( 2 5 Points ) : Consider you recently started a restaurant which opens from 8 . 0 0 AM to 9 .

Question 2(25 Points): Consider you recently started a restaurant which opens from 8.00AM to 9.00PM, Sunday to Friday. Write a python program that does the following:
I. Take input of day as integer. Here, Monday =1, Tuesday =2,dots. Sunday =7.
II. Take the time (in hour) input in 24-hour format. In 24-hour format 10 means 10AM and 20 means 10PM.
III. Determine whether the restaurant is open or close at the time and date.
Check the following sample Input/Output for understanding.
Sample Input 1:
Input Day: 4
Input Time: 17
output: restaurant is open.
Sample Input 2:
Input Day: 4
Input Time: 22
Output: restaurant is close.
You must test the following two test cases with your code and attach the output.
Sample Input 1:
Input Day: 6
Input Time: 14
output: ???
Sample Input 2:
Input Day: 5
Input Time: 13
Output: ????
 Question 2(25 Points): Consider you recently started a restaurant which opens

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!