Question: Problem 1: [5 marks] Display the day of a week ( filename: DisplayDayOfWeek.java) Design an algorithm and then write a program that gets an integer
Problem 1: [5 marks] Display the day of a week (filename: DisplayDayOfWeek.java)
Design an algorithm and then write a program that gets an integer between 0 and 6 from the user. Display the corresponding day of the week on the console (0 Sunday, 1 Monday, and so on). If the user enters an invalid integer, display an error message. Use a switch statement.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
