#include <iostream>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <algorithm>
#include <cstdlib>
#include <set>
#define LL long long
using namespace std;
const int maxn = 1e5 + 10;
int main()
{
	int n,x,y,t,i,j,x1,y1,t1;
	cin>>n;
	bool yes = true;
	x1 = y1 = t1 = 0;
	for(i=0;i<n;i++){ 
		scanf("%d%d%d",&t,&x,&y);
		if(!yes) continue;	 
		x = abs(x-x1);
		y = abs(y-y1);
		t = abs(t-t1);
		if(    (t>=x+y) && ((t-x-y)%2==0) )   yes = true;
		else {
			yes = false;
			cout<<i+1<<"个不行\n"; 
		}
		x1 = x;    y1 = y;    t1 = t;
    }
    if(yes) printf("Yes\n");
	else printf("No\n");
		
	return 0;
}