Write a program that will ask the user to input a number that will
represent the day of week 0 for Sunday, 1 for Monday, 2 for Tuesday, 3 for
Wednesday, 4 for Thursday, 5 for Friday, and 6 for Saturday. Once the user gives the number that represents
the day of the week, it will display the day on the screen.
My email address is the following jakerpomperada@gmail.com, jakerpomperada@aol.com, and jakerpomperada@yahoo.com.
My mobile number here in the Philippines is 09173084360.
My telephone number at home here in Bacolod City, Negros Occidental Philippines is +63 (034) 4335675.
Here in Bacolod City, Negros Occidental I also accepting computer repair, web development using WordPress, Computer Networking, and Arduino Project development at a very affordable price.
My personal website is http://www.jakerpomperada.com
My programming website is http://www.jakerpomperada.blogspot.com
I am also a book author you can purchase my books on computer programming and information technology in the following links below.
https://www.unlimitedbooksph.com/
Program Listing
def week(i):
switcher = {
0: 'Sunday',
1: 'Monday',
2: 'Tuesday',
3: 'Wednesday',
4: 'Thursday',
5: 'Friday',
6: 'Saturday',
}
return switcher.get(i, "Invalid day of
week")
print();
print("\tDay of the Week
Checker");
print();
x= int(input("\tWhat is the
day? "));
print();
print("\tThe day is "
,week(x),'.');
print();
print("\tEND OF
PROGRAM");
No comments:
Post a Comment