Sunday, October 3, 2010

write a programing to accept the number of days and calculate the number of months they make in c?

#include
#include
void main()
{
int days;
int month;
clrscr();
printf("\n\t Enter the days\t:\t");
scanf("%d",&days);
month=days/30;
days=days%30;
printf("\n\a\a\a\t\tmonth\t:\t%d\n\t\tdays\t:\t%d",month,days);

getch();

}

No comments: