Write a Python program that calculates and displays the time and the week day. Your program should be a menu-driven program that does the following: - Displays the current time in 12-hour format (hh:mm:ss) - Displays the current time in 24-hour format (hh:mm:ss) -Displays the elapsed time of the day in seconds -Displays the remaining time of the day in seconds -Displays the current day of the week -Calculates the day of the week in the past/future (user will enter an integer representing the number of days in the past and the future) The functionality of the program shoudl be represented as menu options. Once the user makes a selection, your program will calculate and display the result associated with the user's selection. Your program should contain the following functions:
Write a Python program that calculates and displays the time and the week day. Your program should be a menu-driven program that does the following:
- Displays the current time in 12-hour format (hh:mm:ss)
- Displays the current time in 24-hour format (hh:mm:ss)
-Displays the elapsed time of the day in seconds
-Displays the remaining time of the day in seconds
-Displays the current day of the week
-Calculates the day of the week in the past/future (user will enter an integer representing the number of days in the past and the future)
The functionality of the program shoudl be represented as menu options. Once the user makes a selection, your program will calculate and display the result associated with the user's selection. Your program should contain the following functions:
1) Menu: this function will be used to display the available choices
a. takes no parameters
2)displayTime24Hour
a. takes a datetime object as parameter
3)displayTime12hour
a. takes a datetime object as parameter
4)displayElapsedTime
a.takes a datetime object as parameter
5)displayRemainingTime
a.takes multiple parameters
6)displayWeekday
a. takes a datetime object as parameter
7)displayCalcWeekDay
a. takes an integer as parameter
Step by step
Solved in 3 steps with 3 images