h,w = map(int,input().split()) ni,nj = map(int,input().split()) zi,zj = map(int,input().split()) if h == 1 or w == 1: print("Yes") exit() if (ni+nj)%2 == (zi+zj)%2: print("No") else: print("Yes")