真正写的话这样可以吗?
#include <stdio.h>
int main()
{
int year = 2008;
int month = 8;
int day = 8;
int sum,flag;
for(month=1;month<8;month++)
{
sum=day+month*30+3;
}
printf( "%d年%d月%d日是该年的第%d天",year,month,day,sum);
return 0;
}
#include <stdio.h>
int main()
{
int year = 2008;
int month = 8;
int day = 8;
int sum,flag;
for(month=1;month<8;month++)
{
sum=day+month*30+3;
}
printf( "%d年%d月%d日是该年的第%d天",year,month,day,sum);
return 0;
}
2019-11-07
举报