Question: (quick respond please) Can someone send me the missing code? (Boolean/Strings) 2) (6 points) Name this python file YourLastNameAlarmTime.py (Example: SpiegelAlarmTime.py) Let the days of
(quick respond please) Can someone send me the missing code? (Boolean/Strings)
| 2) (6 points) Name this python file YourLastNameAlarmTime.py (Example: SpiegelAlarmTime.py) Let the days of the week be equal to the numbers 1 through 7. For Example: 1=Sunday, 2=Monday, 3=Tuesday, ...7=Saturday, and a boolean variable onVacation, return a string of the form "6:00, meaning when the alarm should go off in the morning.. Weekdays, the alarm should go off at "6:00" and on the weekend it should go off at "9:00". However if it is vacation, then on the weekdays it should go off at 9:00 and on the weekends it should be off. |
-
Determine test cases (complete the table below)
-
Write the alarmTime function in Python. This function must return a String value as indicated above. Use the function header below.
-
Write a main function where you print the call to alarmTime using atleast 3 test cases.
Examples: alarmTime(day, onVacation)
alarmTime(2,False) 6:00
alarmTime(7,True) off
alarmTime(2,True) 9:00
#Function header
def def alarmTime(day, onVacation):
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
