import sys

N = int(eval(input()))

t, x, y = 0, 0, 0

for i in range(N):

    in_t, in_x, in_y = list(map(int, input().split()))

    t = in_t - t

    x = abs(in_x - x)

    y = abs(in_y - y)

    if (t >= x + y) & ((t - (x + y)) % 2 == 0):

        continue

    print('No')

    sys.exit()

print('Yes')
import sys

N = int(eval(input()))

for _ in range(N):

    t, x, y = list(map(int, input().split()))

    if (t >= x + y) & ((t - (x + y)) % 2 == 0):

        continue

    print('No')

    sys.exit()

print('Yes') 
import sys

N = int(eval(input()))
t, x, y = 0, 0, 0
for i in range(N):
    in_t, in_x, in_y = list(map(int, input().split()))
    t = in_t - t
    x = abs(in_x - x)
    y = abs(in_y - y)
    if (t >= x + y) & ((t - (x + y)) % 2 == 0):
        continue
    print("No")
    sys.exit()
print("Yes")

import sys

N = int(eval(input()))
for _ in range(N):
    t, x, y = list(map(int, input().split()))
    if (t >= x + y) & ((t - (x + y)) % 2 == 0):
        continue
    print("No")
    sys.exit()
print("Yes")

-t, x, y = 0, 0, 0 -for i in range(N): -    in_t, in_x, in_y = list(map(int, input().split())) -    t = in_t - t -    x = abs(in_x - x) -    y = abs(in_y - y) +for _ in range(N): +    t, x, y = list(map(int, input().split()))