Can u help me in my assignment in making a calendar program using turbo c.
I have made a few functions but im now stuck. What will I do with this?
User is asked to input year and month, then the out put will be the year and the Calendar of the month inputed...
pls help me.. asap
#include<stdio.h>
void printMonth (int startDay, int days);
int main (void)
{
printfMonth(2,29);
return 0;
}
/*======printMonth===========*/
void printMonth (int startDay, int days)
{
int weekDay;
int dayCount = 0;
{
printf("Sun Mon Tue Wed Thu Fri Sat\n");
printf("--- --- --- --- --- --- ---\n");
for (weekDay= 0; weekDay < startDay; weekDay++)
{printf(" ");}
for (int dayCount = 1; dayCount <= days; dayCount++)
{
if (weekDay > 6)
{
printf("\n");
weekDay = 1;
}
else
weekDay++;
printf("%3d", daycount);
}
printf("\n--- --- --- --- --- --- ---\n");
return;
}}