implicit none
integer :: n
integer :: i,t,x,y,nt,nx,ny,dt,dxy

read *,n
t = 0
x = 0
y = 0

do i = 1, n
   read *,nt,nx,ny
   dt = nt - t
   dxy = abs(nx - x) + abs(ny - y)
   if (dxy > dt .or. mod(dxy,2) /= mod(dt,2)) then
      print '(a)','No'
      stop
   endif
   t = nt
   x = nx
   y = ny
enddo
print '(a)','Yes'
end