Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

C++ I need help : i want to create a class with all the necessary functions and

ID: 663232 • Letter: C

Question

C++

I need help :

i want to create a class with all the necessary functions and when i write my main

and the class must take into account leap year to check if February is 29 days otherwise it is 28 .

start dating from january 1,1500 where january 1 of the year 1500 is Monday .

I must only use those simple header : (classes header .h if necessary )

# include

# include

using namespace std ;

int main()

{

calendarType cal( 9, 2015 ) ;

cal.print() ;

return 0;

}

The Ouput must be like This: The Implementation of the function that can generate the calendar format is very important to me. please use concepts we see until we meet classes .Thanks in advance .

Explanation / Answer

#include int is_leap_year(int year) { return (!(year % 4) && year % 100 || !(year % 400)) ? 1 : 0; } int main() { int test_case[] = {1900, 1994, 1996, 1997, 2000}, key, end, year; for (key = 0, end = sizeof(test_case)/sizeof(test_case[0]); key