subject

Write a program to generate the entire calendar for one year. the program must get two values from the user: (1) the year and (2) the day of the week for january 1st of that year. the year, which should be positive, is needed to check for and handle leap years1. the day of the week for january 1st is needed so that you know where to start the calendar. the user should enter 0 for sunday, 1 for monday, … or 6 for saturday. as always, you need to validate the user's input. to actually print the calendar, you must use a single method that prints out the calendar for one month and then call this function 12 times from once for each month in the year. to check for a leap year you will need to write another method that takes the year as a parameter and returns true if it’s a leap year, or false otherwise. stubs (i. e. method signatures without any code) for both of these methods have been provided for you. the calendar should be printed in the form below. in this example, january starts on a saturday (day 6). note that february starts on a tuesday in this example because january ended on a monday

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 18:20
Write the pseudocode for the following: a function called fahrenheittocelsius that accepts a real fahrenheit temperature, performs the conversion, and returns the real celsius temperature. a function called celsiustofahrenheit that accepts a real celsius temperature, performs the conversion, and returns the real fahrenheit temperature. a main module that asks user to enter a fahrenheit temperature, calls the fahrenheittocelsius function, and displays the celsius temperature with a user-friendly message. it then asks the user to enter a celsius temperature, calls the celsiustofahrenheit function, and displays the fahrenheit temperature with a user-friendly message.
Answers: 1
question
Computers and Technology, 22.06.2019 02:00
What is the process in which the software development team compiles information to determine the final product.
Answers: 3
question
Computers and Technology, 23.06.2019 14:30
The basic work area of the computer is it screen that you when you first fire up your computer
Answers: 1
question
Computers and Technology, 24.06.2019 01:30
How can you make your column headings stand out?
Answers: 1
You know the right answer?
Write a program to generate the entire calendar for one year. the program must get two values from t...
Questions
question
Mathematics, 18.10.2020 16:01
question
History, 18.10.2020 16:01
question
Mathematics, 18.10.2020 16:01
question
History, 18.10.2020 16:01
question
Mathematics, 18.10.2020 16:01
Questions on the website: 13722359