Question: I use C++ compiler .validate the user input such that the month is in the range 1-12 and the year is after 4713 BC. NOTE:

 I use C++ compiler .validate the user input such that the

I use C++ compiler

.validate the user input such that the month is in the range 1-12 and the year is after 4713 BC. NOTE: Consider using a while loop with appropriate conditions. print the name of the month and year .print the days of the week. Note: Each day should be left justified in a field with 11 characters print the first week using leading blank fields (11 spaces) prior to the first day of the month. NOTE: This MUST be done using a loop. Consider how the modulo of the Julian day from Milestone 1 relates to the number of blank fields needed. print the remaining days of the week with proper formatting such that the day number is left justified in the 11 character field. NOTE: This MUST be done using a loop. Consider logic to determine the number of trailing spaces for single digit days vs. two digit days for proper spacing. Here is an example run of the program for Milestone 2 (user input in bold) Enter month and year: 9 2018 There are 30 days in the month The month starts on a Saturday September 2018 Sunday Monday Tusday Wednesday Thursday Friday Saturday 10 17 12 19 26 13 14 21 28 15 16 23 30 18 25 27 29 Another example run (user input in bold) Enter month and year: 13 2012 Invalid date, please re-enter month and year: 10 -5080 Invalid date, please re-enter month and year: 2 2018 There are 28 days in the month The month starts on a Thursday February 2818 Sunday onday Tuesday Wednesday Thursday Friday Saturday 1e 17 12 19 26 15 18 25 13 20 27 14 21 28 16 23 Approach Hints Separating weeks Consider using multiple counters for which day is currently being printed and for the number of days previously printed to determine when a new week starts in order to begin the next line of output

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!