semeru/Code-Code-CloneDetection-POJ104 huggingface dataset:
int main()
{
	int year,month,day,i,sum=0;
	scanf("%d%d%d",&year,&month,&day);
	int a[2][12]={{31,28,31,30,31,30,31,31,30,31,30,31},{31,29,31,30,31,30,31,31,30,31,30,31}};
	if(year%4==0&&year%100!=0||year%400==0)
	{
		for(i=0;i<month;i++)
			sum+=a[1][i];
		sum=sum+day-a[1][month-1];
	}
	else
	{
		for(i=0;i<month;i++)
			sum+=a[0][i];
		sum=sum+day-a[0][month-1];
	}
	printf("%d", sum);
	return 0;
}
int main()
{
	int i,a[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	int sum=0,days,year,month;
	scanf("%d%d%d",&year,&month,&days);
    for(i=0;i<month-1;i++)
	{	sum=sum+a[i];}
	sum=sum+days;
	if((month==2&&days>=28)||(month>2))
	{
	     if((year%4==0&&year%100!=0)||(year%400==0))
	          sum=sum+1;
	}
	printf("%d\n",sum);
	return 0;
}
main()
{
      int leap(int x);
      int a,b,c,t,i;
      scanf("%d %d %d",&a,&b,&c);
      t=0;
      if(leap(a)==1)
      {
                   for(i=1;i<b;i++)
               {
                   if(i==1||i==3||i==5||i==7||i==8||i==10||i==12)
                   t=t+31;
                   if(i==2)
                   t=t+29;
                   if(i==4||i==6||i==9||i==11)
                   t=t+30;
                   }
                   t=t+c;
          printf("%d",t);
          }
      if(leap(a)==0)
      {
             for(i=1;i<b;i++)
               {
                   if(i==1||i==3||i==5||i==7||i==8||i==10||i==12)
                   t=t+31;
                   if(i==2)
                   t=t+28;
                   if(i==4||i==6||i==9||i==11)
                   t=t+30;
                   }
                   t=t+c;
             printf("%d",t);
             }
                  getchar();
                  getchar();
                    }
int leap(int x)
{
    int leap;
    if((x%4==0&&x%100!=0)||(x%400==0))
       leap=1;
    else 
       leap=0;
    return leap;
}
int main(int argc, char* argv[]) 
{ 
	int a,b,c,s=0;
	scanf("%d%d%d",&a,&b,&c);
	 int   m1=31,
		m2=28,
		m21=29,
		m3=31,
		m4=30,
		m5=31,
		m6=30,
		m7=31,
		m8=31,
		m9=30,
		m10=31,
		m11=30,
		m12=31;
		if (a%4!=0||(a%100==0&&a%400!=0))
		{switch(b) 
		{	case(1):
		s=c;
		printf("%d\n",s);break;
 	case(2):
		
		s=31+c;
		printf("%d\n",s);break;
	case(3):
			s=31+28+c;
			printf("%d\n",s);break;

	case(4):
				s=m1+m2+m3+c;
				printf("%d\n",s);break;

	case(5):
				s=m1+m2+m3+m4+c;
				printf("%d\n",s);break;
	case(6):
s=m1+m2+m3+m4+m5+c;
	printf("%d\n",s);break;

	case(7):
s=m1+m2+m3+m4+m5+m6+c;
	printf("%d\n",s);break;
	case(8):
s=m1+m2+m3+m4+m5+m6+m7+c;
	printf("%d\n",s);break;
	case(9):
s=m1+m2+m3+m4+m5+m6+m7+m8+c;
	printf("%d\n",s);break;
	case(10):
s=m1+m2+m3+m4+m5+m6+m7+m8+m9+c;
printf("%d\n",s);break;
	case(11):
s=m1+m2+m3+m4+m5+m6+m7+m8+m9+m10+c;
	printf("%d\n",s);break;
	case(12):
s=m1+m2+m3+m4+m5+m6+m7+m8+m9+m10+m11+c;
	printf("%d\n",s);break;
		}}
		else
		{
			switch (b)
			{	case(1):
		s=c;
	printf("%d\n",s);break;
			case(2):
		
		s=31+c;
		printf("%d\n",s);break;
			case(3):
			s=31+29+c;
			printf("%d\n",s);break;

			case(4):
				s=m1+m21+m3+c;
				printf("%d\n",s);break;

			case(5):
				s=m1+m21+m3+m4+c;
				printf("%d\n",s);break;
			case(6):
s=m1+m21+m3+m4+m5+c;
	printf("%d\n",s);break;

			case(7):
s=m1+m21+m3+m4+m5+m6+c;
	printf("%d\n",s);break;
			case(8):
s=m1+m21+m3+m4+m5+m6+m7+c;
	printf("%d\n",s);break;
			case(9):
s=m1+m21+m3+m4+m5+m6+m7+m8+c;
	printf("%d\n",s);break;
			case(10):
s=m1+m21+m3+m4+m5+m6+m7+m8+m9+c;
printf("%d\n",s);break;
			case(11):
s=m1+m21+m3+m4+m5+m6+m7+m8+m9+m10+c;
	printf("%d\n",s);break;
			case(12):
s=m1+m21+m3+m4+m5+m6+m7+m8+m9+m10+m11+c;
	printf("%d\n",s);break;
		}}
	return 0;
}
main()
{
      int a,b,c,n=0;
      scanf("%d %d %d",&a,&b,&c);
      if(a%4==0&&a%100!=0)
      a=0;
      if(a%100==0&&a%400==0)
      a=0;
      if(a!=0)
      {
              switch (b-1)
              {
                     case 12:n=n+31;
                     case 11:n=n+30;
                     case 10:n=n+31;
                     case 9:n=n+30;
                     case 8:n=n+31;
                     case 7:n=n+31;
                     case 6:n=n+30;
                     case 5:n=n+31;
                     case 4:n=n+30;
                     case 3:n=n+31;
                     case 2:n=n+28;
                     case 1:n=n+31;
              }
              n=n+c;
              printf("%d",n);
      }
      if(a==0)
      {
              switch (b-1)
              {
                     case 12:n=n+31;
                     case 11:n=n+30;
                     case 10:n=n+31;
                     case 9:n=n+30;
                     case 8:n=n+31;
                     case 7:n=n+31;
                     case 6:n=n+30;
                     case 5:n=n+31;
                     case 4:n=n+30;
                     case 3:n=n+31;
                     case 2:n=n+29;
                     case 1:n=n+31;
              }
              n=n+c;
              printf("%d",n);
      }
      
      getchar();
      getchar();
}
int main()
  {
	  int year,month,monthd[12]={31,28,31,30,31,30,31,31,30,31,30,31},day,di=0,i;
	  scanf("%d %d %d",&year,&month,&day);
	  for(i=1;i<month;i++)
	  { 
		  di=di+monthd[i-1];
	  }
	  di=di+day;
	  if((year%4)!=0||(year%400)!=0)
	  {
		  printf("%d\n",di);
	  }
	  else
		  printf("%d",di+1);
	  return 0;
  }
int main(int argc, char* argv[])
{
	int a,b,c;
	scanf("%d%d%d",&a,&b,&c);
	if((a%4==0&&a%100!=0)||a%400==0){
		if(b==1)
			printf("%d",c);
		else if(b==2)
			printf("%d",31+c);
		else if(b==3)
			printf("%d",60+c);
		else if(b==4)
			printf("%d",91+c);
		else if(b==5)
			printf("%d",121+c);
		else if(b==6)
			printf("%d",152+c);
		else if(b==7)
			printf("%d",182+c);
		else if(b==8)
			printf("%d",213+c);
		else if(b==9)
			printf("%d",244+c);
		else if(b==10)
			printf("%d",274+c);
		else if(b==11)
			printf("%d",305+c);
		else if(b==12)
			printf("%d",336+c);}
	else{
		if(b==1)
			printf("%d",c);
		else if(b==2)
			printf("%d",31+c);
		else if(b==3)
			printf("%d",59+c);
		else if(b==4)
			printf("%d",90+c);
		else if(b==5)
			printf("%d",120+c);
		else if(b==6)
			printf("%d",151+c);
		else if(b==7)
			printf("%d",181+c);
		else if(b==8)
			printf("%d",212+c);
		else if(b==9)
			printf("%d",243+c);
		else if(b==10)
			printf("%d",273+c);
		else if(b==11)
			printf("%d",304+c);
		else if(b==12)
			printf("%d",335+c);}

	return 0;
}
int main()
{

  int year,month,day;
  int days[12]={31,28,31,30,31,30,31,31,30,31,30,31};
   scanf("%d %d %d",&year,&month,&day);

  if (year%4!=0)
	  days[1]=28;
  else if (year%4==0&&year%100!=0)
	  days [1]=29;
  else if (year%400==0)
      days [1]=29;
  else if (year%100==0&&year%400!=0)
      days [1]=28;
  int i,k=0,n;
  for (i=1;i<month;i++)
  { 
	  k=k+days[i];
  }
     n=k+day+1;
	 printf ("%d\n",n);
	 return 0;
}
int leap(int year){
	if((year%4==0 && year%100!=0) || year%400==0)
		return 1;
	else{
		return 0;
	}
}
void main(){
	int year,month,day;
	int days,i;
	days=0;
	scanf("%d%d%d",&year,&month,&day);
	for(i=1;i<month;i++){
		if(i==1 || i==3 || i==5 || i==7 || i==8 || i==10 || i==12)
			days+=31;
		if(i==4 || i==6 || i==9 || i==11)
			days+=30;
		if(i==2){
			if(leap(year))
				days+=29;
			else{
				days+=28;
			}
		}
	}
	days+=day;
	printf("%d\n",days);
}
void main()
{  
  int y,m,d,t,i;
  for(i=1;i<=5;)
  {
    scanf("%d %d %d",&y,&m,&d);
    if ((y%4==0&&y%100!=0)||(y%400==0))
    {
      switch(m)
      {
        case 1: t=d;break;
        case 2: t=d+31;break;
        case 3: t=d+60;break;
        case 4: t=d+91;break;
        case 5: t=d+121;break;
        case 6: t=d+152;break;
        case 7: t=d+182;break;
        case 8: t=d+213;break;
        case 9: t=d+244;break;
        case 10: t=d+274;break;
        case 11: t=d+305;break;
        case 12: t=d+335;break;
      }  
    }
    else
    {
      switch(m)
      {
        case 1: t=d;break;
        case 2: t=d+31;break;
        case 3: t=d+59;break;
        case 4: t=d+90;break;
        case 5: t=d+120;break;
        case 6: t=d+151;break;
        case 7: t=d+181;break;
        case 8: t=d+212;break;
        case 9: t=d+243;break;
        case 10: t=d+273;break;
        case 11: t=d+304;break;
        case 12: t=d+334;break;
      }
    }
    printf("%d\n",t);
    i++;
  }
}
int main()
{
int mouth[2][12]={{31,28,31,30,31,30,31,31,30,31,30,31},{31,29,31,30,31,30,31,31,30,31,30,31}};
int leapyear;
int a,b,c,i;
int d=0;
scanf("%d %d %d",&a,&b,&c);
leapyear=(a%4==0&&a%100!=0||a%400==0);
for(i=0;i<b-1;i++)
{
    d=d+mouth[leapyear][i];
}
d=d+c;
printf("%d",d);
return 0;
}
int main()
{
	int y,m,d,s,i,l;
	s=0;
	scanf("%d %d %d",&y,&m,&d);
	int a[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};
	for(i=1;i<m;i++){
		s=s+a[i];
	}
	s=s+d;
	if(y%4==0){
		if(y%100==0){
			if(y%400==0)
				l=1;
			else l=0;
		}
		else l=1;
	}
	else l=0;
	if(m>2) s=s+l;
    printf("%d\n",s);
    return 0;
}
int a[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};

int main(){
	int year,month,day,num=0;
	cin>>year>>month>>day;
	if((year%4==0 && year%100!=0)||(year%400==0))
		a[2]++;
	for(int i=1;i<month;i++)
		num+=a[i];
	num+=day;
	cout<<num<<endl;
	return 0;
}
int main()
{
	int k,j=0,y,i,m,d,number[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	scanf("%d %d %d",&y,&m,&d);
	for(i=1;i<m;i++)
	{j+=number[i-1];}
    k=j+d;
    if(y%4==0&&y%100!=0||y%400==0){
		if(m>1)
			printf("%d",k+1);}
	else
		printf("%d",k);
	return 0;
}
int f(int y)
{
    int i;
    if(y%4==0)
    {
              if(y%100==0)
              {
                          if(y%400==0)
                            return(1);
                          else
                            return(0);
              }
              else
               return(1);
     }
     else
      return(0);
}
int main()  
{
      int y,m,d,n,i;int a[13];
      a[1]=31;a[3]=31;a[4]=30;a[5]=31;a[6]=30;a[7]=31;a[8]=31;
      a[9]=30;a[10]=31;a[11]=30;a[12]=30;
      n=0;
      scanf("%d %d %d",&y,&m,&d);
      if(f(y)==0) a[2]=28;
      if(f(y)==1) a[2]=29;
       for(i=1;i<m;i++)
           n=a[i]+n;
      n=n+d;
      printf("%d",n);
      getchar();getchar();
}
int main()
{
	int year,month,day,n,i,t=0;
	scanf("%d%d%d",&year,&month,&day);
	int a[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};
	for(i=0;i<month;i++)
	{
		t=t+a[i];
	}
	if(month>=3)
		if(year%4==0)
			if(year%100==0)
				if(year%400==0)
					n=t+1+day;
				else
					n=t+day;
				else
					n=t+1+day;
				else
					n=t+day;
				else
					n=t+day;

	printf("%d",n);
	return 0;			
			
}
int m(int n)
{
    if (n%100!=0)
    {
                 if(n%4==0)
                 return(1);
                 else
                 return(0);
    }
    else
    {
        if(n%400==0)
        return(1);
        else
        return(0);
    }
    
}
main()
{
      int a,b,c,x=0,i;
      scanf("%d %d %d",&a,&b,&c);
      if(m(a)==1)
      {
                 int d[]={31,29,31,30,31,30,31,31,30,31,30};
                 for(i=1;i<b;i++)
                 x=x+d[i-1];
                 x=x+c;
      }
      else
      {
                 int d[]={31,28,31,30,31,30,31,31,30,31,30};
                                  for(i=1;i<b;i++)
                 x=x+d[i-1];
                 x=x+c;
      }
      printf("%d",x);
      getchar();
      getchar();
}
int f(int x)
{
 int z;
 if((x%4==0)&&(x%100!=0)||(x%400==0)) z=1;
 else z=0;
 return z;
 }
main()
{
 int year,month,day;
 scanf("%d %d %d",&year,&month,&day);
 int z,i,sum=0;
 z=f(year);
 int a[12];
 if(z==1) {int a[]={31,29,31,30,31,30,31,31,30,31,30,31};
 for(i=0;i<month-1;i++)
 {
 sum=sum+a[i];
 }}
 else {int a[]={31,28,31,30,31,30,31,31,30,31,30,31};
 for(i=0;i<month-1;i++)
 {
 sum=sum+a[i];
 }}
 sum=sum+day;
 printf("%d",sum);
 getchar();
 getchar();
 return 0;
 }
int main(int argc, char* argv[])
{
    int d[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	int year,month,day,i,days=0;
	scanf("%d%d%d",&year,&month,&day);
    for(i=1;i<month;i++)
	{
		days=days+d[i-1];
	}
	days=days+day;
	if((year%4==0||year%400==0)&&month>2)
		days=days++;
	printf("%d",days);
}
int main()
{
   int y,m,d,n; 
   scanf("%d",&y);
   if((y%4==0&&y%100!=0)||(y%400==0))
   {
	   scanf("%d%d",&m,&d);
	if(m==1)
	{n=d;}
	if(m==2)
	{n=31+d;}
	if(m==3)
	{n=31+29+d;}
	if(m==4)
	{n=31+29+d+31;}
	if(m==5)
	{n=31+29+d+31+30;}
	if(m==6)
	{n=31+29+d+31+30+31;}
	if(m==7)
	{n=31+29+d+31+30+31+30;}
    if(m==8)
	{n=31+29+d+31+30+31+30+31;}
	if(m==9)
	{n=31+29+d+31+30+31+30+31+31;}
	if(m==10)
	{n=31+29+d+31+30+31+30+31+31+30;}
	if(m==11)
	{n=31+29+d+31+30+31+30+31+31+30+31;}
	if(m==12)
	{n=31+29+d+31+30+31+30+31+31+30+31+30;}
	printf("%d",n);
   
   }
   else
    {
	   scanf("%d%d",&m,&d);
	if(m==1)
	{n=d;}
	if(m==2)
	{n=31+d;}
	if(m==3)
	{n=31+28+d;}
	if(m==4)
	{n=31+28+d+31;}
	if(m==5)
	{n=31+28+d+31+30;}
	if(m==6)
	{n=31+28+d+31+30+31;}
	if(m==7)
	{n=31+28+d+31+30+31+30;}
    if(m==8)
	{n=31+28+d+31+30+31+30+31;}
	if(m==9)
	{n=31+28+d+31+30+31+30+31+31;}
	if(m==10)
	{n=31+28+d+31+30+31+30+31+31+30;}
	if(m==11)
	{n=31+28+d+31+30+31+30+31+31+30+31;}
	if(m==12)
	{n=31+28+d+31+30+31+30+31+31+30+31+30;}
	printf("%d",n);
   
   }
   return 0;
   }
int main(){
	int year,month,day,sum,i;
	int N[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	scanf("%d %d %d",&year,&month,&day);
    sum=0;
	for(i=1;i<month;i++){
		sum=sum+N[i-1];}
    if((year%4==0&&year%100!=0)||year%400==0) sum=sum+1;
	sum=sum+day;
    printf("%d",sum );
	
}
int main()
{   
	long int a[5],b[5],c[5],ts[5],i;
	for(i=1;i<=5;i++)
	scanf("%ld %ld %ld",&a[i],&b[i],&c[i]);
	for(i=1;i<=5;i++)
	{
	switch(b[i])
	{
case 1:ts[i]=c[i];break;
case 2:ts[i]=c[i]+31;break;
case 3:ts[i]=c[i]+59;break;
case 4:ts[i]=c[i]+90;break;
case 5:ts[i]=c[i]+120;break;
case 6:ts[i]=c[i]+151;break;
case 7:ts[i]=c[i]+181;break;
case 8:ts[i]=c[i]+212;break;
case 9:ts[i]=c[i]+243;break;
case 10:ts[i]=c[i]+273;break;
case 11:ts[i]=c[i]+304;break;
case 12:ts[i]=c[i]+334;break;
	}
	
	if((a[i]%4==0&&a[i]%100!=0||a[i]%400==0)&&b[i]>2)
		ts[i]=ts[i]+1;
	
	printf("%ld",ts[i]);
	printf("\n");
	
	}
	return 0;
}
void main()
{
 int i;
 int sum_day(int,int);
 int leap(int year);
 int year[5],month[5],day[5],days[5];
 for(i=0;i<5;i++)
 scanf("%d%d%d",&year[i],&month[i],&day[i]);
 for(i=0;i<5;i++)
 {days[i]=sum_day(month[i],day[i]);
 if(leap(year[i])&&month[i]>=3)
  days[i]=days[i]+1;
 printf("%d\n",days[i]);}
}
   int sum_day(int month,int day)
   {int day_tab[13]={0,31,28,31,30,31,30,31,31,30,31,30,31};
    int i;
    for(i=1;i<month;i++)
      day+=day_tab[i];
    return(day);
   }

  int leap(int year)
   {int leap;
    leap=year%4==0&&year%100!=0||year%400==0;
    return(leap);
   }
int main()
{
	int a,b,c,d;
	scanf("%d%d%d",&a,&b,&c);
	if((a%4==0&&a%100!=0)||a%400==0)
		switch(b){
		    case 1:
			    d=c;
			    break;
		    case 2:
			    d=31+c;
			    break;
		    case 3:
			    d=60+c;
			    break;
		    case 4:
			    d=91+c;
			    break;
		    case 5:
   			    d=121+c;
                break;
		    case 6:
			    d=152+c;
			    break;
		    case 7:
			    d=182+c;
			    break;
		    case 8:
			    d=213+c;
			    break;
		    case 9:
			    d=244+c;
			    break;
		    case 10:
			    d=274+c;
			    break;
		    case 11:
			    d=305+c;
			    break;
		    case 12:
			    d=335+c;
			    break;
		    default :
			    d=0;
	}
	else
		switch(b){
			case 1:
				d=c;
				break;
			case 2:
				d=31+c;
				break;
			case 3:
				d=59+c;
				break;
			case 4:
				d=90+c;
				break;
			case 5:
   				d=120+c;
                break;
			case 6:
				d=151+c;
				break;
			case 7:
				d=181+c;
				break;
			case 8:
				d=212+c;
				break;
			case 9:
				d=243+c;
				break;
			case 10:
				d=273+c;
				break;
			case 11:
				d=304+c;
				break;
			case 12:
				d=334+c;
				break;
			default :
	            d=0;
	}
    printf("%d\n",d);
	return 0;
}
int l(int a)
{
	int i,j,k;
	i = a % 4;
	j = a % 100;
	k = a % 400;
	if(i==0)
	{
		if(j!=0||k==0)
	        return 1;
		else
			return 0;
	}
	else
		return 0;
}
int main()
{
	int a[3],i,j,k=0;
	int b[12] ={0,31,28,31,30,31,30,31,31,30,31,30};
	int c[12] = {0,31,29,31,30,31,30,31,31,30,31,30};
	int d[12];
	cin >> a[0] >> a[1] >> a[2];
	i = a[0];
	if(l(i)==1)
	{
		for(j=0;j<12;j++)
			d[j] = c[j];
	}
	else
	{
		for(j=0;j<12;j++)
			d[j] = b[j];
	}
	for(i=0;i<a[1];i++)
		k = d[i] + k;
	k = k + a[2];
	cout << k <<endl;
	return 0;
}
main()
{
      int Y,M,D;
      scanf("%d %d %d",&Y,&M,&D);
      if(Y%400==0&&Y%4000!=0)
      {
           if(M==1)
           printf("%d",D);           
           if(M==2)
           printf("%d",D+31);
           if(M==3)
           printf("%d",D+60);
           if(M==4)
           printf("%d",D+91);
           if(M==5)
           printf("%d",D+121);
           if(M==6)
           printf("%d",D+151);
           if(M==7)
           printf("%d",D+182);
           if(M==8)
           printf("%d",D+213);
           if(M==9)
           printf("%d",D+244);
           if(M==10)
           printf("%d",D+274);
           if(M==11)
           printf("%d",D+305);
           if(M==12)
           printf("%d",D+335);
      }
      else if(Y%4==0&&Y%100!=0)
      {
           if(M==1)
           printf("%d",D);           
           if(M==2)
           printf("%d",D+31);
           if(M==3)
           printf("%d",D+60);
           if(M==4)
           printf("%d",D+91);
           if(M==5)
           printf("%d",D+121);
           if(M==6)
           printf("%d",D+151);
           if(M==7)
           printf("%d",D+182);
           if(M==8)
           printf("%d",D+213);
           if(M==9)
           printf("%d",D+244);
           if(M==10)
           printf("%d",D+274);
           if(M==11)
           printf("%d",D+305);
           if(M==12)
           printf("%d",D+335);
      }
      else
      {
           if(M==1)
           printf("%d",D);           
           if(M==2)
           printf("%d",D+31);
           if(M==3)
           printf("%d",D+59);
           if(M==4)
           printf("%d",D+90);
           if(M==5)
           printf("%d",D+120);
           if(M==6)
           printf("%d",D+150);
           if(M==7)
           printf("%d",D+181);
           if(M==8)
           printf("%d",D+212);
           if(M==9)
           printf("%d",D+243);
           if(M==10)
           printf("%d",D+273);
           if(M==11)
           printf("%d",D+304);
           if(M==12)
           printf("%d",D+334);
      }
}
void main()
{
	struct date
	{
		int year;
		int month;
		int day;
		int days;
	}date1;
	scanf("%d %d %d",&date1.year,&date1.month,&date1.day);
    int b[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	date1.days=0;
	int i;
	if (date1.month>1)
	{
		for ( i=0;i<=date1.month-2;i++)
		{
			date1.days=date1.days+b[i];
		}
		date1.days=date1.days+date1.day;
	}
	else 
	{
		date1.days=date1.day;
	}
	printf("%d",date1.days);
}
int main()
{
	int a,b,c,d;
	scanf("%d%d%d",&a,&b,&c);
	if ((a%4==0&&a%400==0)||(a%4==0&&a%100!=0))
	{	if(b==1)
			d=c;
		if(b==2)
			d=31+c;
        if(b==3)
			d=31+29+c;
		if(b==4)
			d=31+29+31+c;
		if(b==5)
			d=31+29+31+30+c;
		if(b==6)
			d=31+29+31+30+31+c;
		if(b==7)
			d=31+29+31+30+31+30+c;
		if(b==8)
         d=31+29+31+30+31+30+31+c;
		if(b==9)
d=31+29+31+30+31+30+31+c+31;
		if(b==10)
d=31+29+31+30+31+30+31+c+31+30;
		if(b==11)
			d=31+29+31+30+31+30+31+c+31+30+31;
		if(b==12)
		d=31+29+31+30+31+30+31+c+31+30+31+30;
	
		printf("%d",d);}
		
			else 
			{
        if(b==1)
			d=c;
		if(b==2)
			d=31+c;
        if(b==3)
			d=31+28+c;
		if(b==4)
			d=31+28+31+c;
		if(b==5)
			d=31+28+31+30+c;
		if(b==6)
			d=31+28+31+30+31+c;
		if(b==7)
			d=31+28+31+30+31+30+c;
		if(b==8)
         d=31+28+31+30+31+30+31+c;
		if(b==9)
d=31+28+31+30+31+30+31+c+31;
		if(b==10)
d=31+28+31+30+31+30+31+c+31+30;
		if(b==11)
			d=31+28+31+30+31+30+31+c+31+30+31;
		if(b==12)
		d=31+28+31+30+31+30+31+c+31+30+31+30;
			
		printf("%d",d);
			}
		
		return 0;





			

}
int main(int argc, char* argv[])
{
	int year,month,day;
	scanf("%d%d%d",&year,&month,&day);
	if(year%4!=0||(year%100==0&&year%400!=0))
	{if (month==1)
		printf("%d",day);
	else if(month==2)
		printf("%d",day+31);
    else if(month==3)
	    printf("%d",day+59);
	else if(month==4)
		printf("%d",day+90);
    else if(month==5)
		printf("%d",day+120);
    else if(month==6)
	    printf("%d",day+151);
	else if(month==7)
		printf("%d",day+181);
    else if(month==8)
		printf("%d",day+212);
    else if(month==9)
	    printf("%d",day+242);
	else if(month==10)
		printf("%d",day+273);
    else if(month==11)
		printf("%d",day+304);
    else if(month==12)
		printf("%d",day+334);
}
	else 
{if (month==1)
		printf("%d",day);
	else if(month==2)
		printf("%d",day+31);
    else if(month==3)
	    printf("%d",day+59+1);
	else if(month==4)
		printf("%d",day+90+1);
    else if(month==5)
		printf("%d",day+120+1);
    else if(month==6)
	    printf("%d",day+151+1);
	else if(month==7)
		printf("%d",day+182);
    else if(month==8)
		printf("%d",day+213);
    else if(month==9)
	    printf("%d",day+243);
	else if(month==10)
		printf("%d",day+274);
    else if(month==11)
		printf("%d",day+305);
    else if(month==12)
		printf("%d",day+335);
}

	
	return 0;
}
void main()
{
	int y,d,m,i,j,e=0,total=0;
	int a[12]={31,28,31,30,31,30,31,31,30,31,30,31};
	scanf("%d%d%d",&y,&m,&d);
	if (((y%4==0)&&(y%100!=0))||(y%400==0)) a[1]=29;
	for(i=1;i<m;i++)
	{
		total+=a[i-1];
	}
	total+=d;
	printf("%d\n",total);
}
int main()
{
	int  a,b,c,D;
	scanf("%d %d %d",&a,&b,&c);
	if(((a%4==0)&&(a%100!=0))||(a%400==0))
	{
		switch(b)
		{
		case 1:
			D = c;
			break;
		case 2:
			D = c +31;
			break;

        case 3:
			D = c +60;
			break;
        case 4:
			D = c + 91;
			break;
        case 5:
			D = c + 121;
			break;
        case 6:
			D = c + 152;
			break;
        case 7:
			D = c + 182;
			break;
        case 8:
			D = c + 213;
			break;
        case 9:
			D = c + 244;
			break;
        case 10:
			D = c + 274;
			break;
        case 11:
			D = c + 305;
			break;
        case 12:
			D = c + 335;
			break;

 
		}
		printf("%d",D);
		

	}
	else 
	{
		switch(b)
		{
		case 1:
			D = c;
			break;
		case 2:
			D = c +31;
			break;

        case 3:
			D = c +60-1;
			break;
        case 4:
			D = c + 91-1;
			break;
        case 5:
			D = c + 121-1;
			break;
        case 6:
			D = c + 152-1;
			break;
        case 7:
			D = c + 182-1;
			break;
        case 8:
			D = c + 213-1;
			break;
        case 9:
			D = c + 244-1;
			break;
        case 10:
			D = c + 274-1;
			break;
        case 11:
			D = c + 305-1;
			break;
        case 12:
			D = c + 335-1;
			break;
		}
			
		printf("%d",D);
		

	}
	
	return 0;
}
static int days[13] = {0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}; 


static int isleapyear(int year)
 { 
  return (year % 4 == 0 && year % 100 !=0 ) || year % 400 == 0; 
} 

int main() { 
  int year, month, day; 
  scanf("%d %d %d", &year, &month, &day); 
  

  int n = 0;  
  int i; 
  for (i = 1; i < month; i++) 
  { 
    n += days[i]; 
  } 
 
  n += day; 
  
  if (month > 2 && isleapyear(year)) 
    n++; 

  printf("%d", n); 
}
int RunNian(int y)
     {
        int result ;
         if (y%4==0 && y%100!=0|| y%400==0)
         {
                    result=1;
         }
         else
         {
            result=0;
         }
         return result;
     }
         
int DiJiTian(int y,int m,int d)
     {
         int result=0;
          for (int i=1;i<m;i++)
          {
              if(i==1||i==3||i==5||i==7||i==8||i==10||i==12)
                {
                  result+=31;                                                          
                }
              else if(i==4||i==6||i==9||i==11)
                {
                  result+=30;                           
                }
              else if(i==2)
                {
                   if(RunNian(y)) 
                     {
                      result+=29;
                     }     
                    else
                      {
                       result+=28;
                      }  
                }
          }
          
          result+= d;
          return result; 
     }
        
int main()
{

     int y2,m2,d2,a,e;
     int T=0;
    
       scanf("%d%d%d",&y2,&m2,&d2);
          
          T+= DiJiTian(y2,m2,d2);          
           printf ("%d\n",T);
return 0;
}
int main()
{
	int year,mon,day,num=0,i,a[11];
	scanf("%d %d %d",&year,&mon,&day);
	a[0]=a[2]=a[4]=a[6]=a[7]=a[9]=31;
	a[3]=a[5]=a[8]=a[10]=30;
	if(year%4!=0)
	{
		a[1]=28;
	}
	else if(year%100==0)
	{
		if(year%400==0)
		{
			a[1]=29;
		}
		else a[1]=28;
	}
	else a[1]=29;
	for(i=0;i<mon-1;i++)
	{
		num=num+a[i];
	}
	num=num+day;
	printf("%d",num);
	return 0;
}