Question: C language Description Write a program that reads the year and first day of the year, and displays the first day of each month in

C language

Description

Write a program that reads the year and first day of the year, and displays the first day of each month in the year. For example, if the user entered year 2005, and 6 for Saturday, January 1, 2005, your program should display the following output: January 1, 2005 is Saturday February 1, 2005 is Tuesday March 1, 2005 is Tuesday April 1, 2005 is Friday May 1, 2005 is Sunday June 1, 2005 is Wednesday July 1, 2005 is Friday August 1, 2005 is Monday September 1, 2005 is Thursday October 1, 2005 is Saturday November 1, 2005 is Tuesday December 1, 2005 is Thursday

Input

The year and first day of the year (where 0 is Sunday, 1 is Monday, and so on).

Output

The result like the sample output.

Sample Input

2005 6

Sample Output

January 1, 2005 is Saturday

February 1, 2005 is Tuesday

March 1, 2005 is Tuesday

April 1, 2005 is Friday

May 1, 2005 is Sunday

June 1, 2005 is Wednesday

July 1, 2005 is Friday

August 1, 2005 is Monday

September 1, 2005 is Thursday

October 1, 2005 is Saturday

November 1, 2005 is Tuesday

December 1, 2005 is Thursday

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!