#include<stdio.h>
int yue1[12]={31,28,31,30,31,30,31,31,30,31,30,31};
int yue2[12]={31,29,31,30,31,30,31,31,30,31,30,31};
int main()
{ int f(int year,int month,int date);
int a1,a2,a3;
while(scanf("%d/%d/%d",&a1,&a2,&a3)!=EOF){
f(a1,a2,a3);
}
return 0;
}
int f(int year,int month,int date)
{
int i=0;
if ((year%4==0&&year%100!=0)||year%400==0)
if(month>1)
for(i=0;i<month-1;i++)
date=date+yue2[i];
else
date=date;
else
if(month>1)
for(i=0;i<month-1;i++)
date=date+yue1[i];
else
date=date;
printf("%d\n",date);
return 0;
}
0.0分
6 人评分