Start: Jan, 08, 2019 19:01:00
2018年秋季学期程序设计基础(C语言)期末考试
End: Jan, 08, 2019 21:46:00
Time elapsed:
Time remaining:

Problem_ID: F
Result: Accepted
Time: 7ms
Memory: 1092kB
In contest: 1258

#include<stdio.h>
#include<string.h>
int main()
{
	int x1,x2,y1,y2,z1,z2,flag=0;
	scanf("%d %d %d %d %d %d",&x1,&y1,&z1,&x2,&y2,&z2);
	if(x2==x1) flag=1;
	else
	{
		if(x2==x1+1||(x2==1&&x1==7))
		{	
			if(y1>y2)
			{
				flag=1;
			}
			else if(y1==y2&&z2<=z1)
			{
				flag=1;
			}
		}
	}
	if(flag==1)	printf("Y e s\n");
	else 		printf("N o\n");
	return 0;
}