
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int time = 0; time 0 int x = 0; x 0 int y = 0; y 0 boolean ans = true; ans true for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		} {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		} int nexttime = sc.nextInt(); nexttime sc.nextInt() sc.nextInt sc int nextx = sc.nextInt(); nextx sc.nextInt() sc.nextInt sc int nexty = sc.nextInt(); nexty sc.nextInt() sc.nextInt sc int dtime = nexttime - time; dtime nexttime - time nexttime time int dx = Math.abs(nextx - x); dx Math.abs(nextx - x) Math.abs Math nextx - x nextx x int dy = Math.abs(nexty - y); dy Math.abs(nexty - y) Math.abs Math nexty - y nexty y if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			} dtime >= dx + dy && dtime % 2 == (dx + dy) % 2 dtime >= dx + dy dtime dx + dy dx dy dtime % 2 == (dx + dy) % 2 dtime % 2 dtime 2 (dx + dy) % 2 (dx + dy) dx dy 2 {
				time = nexttime;
				x = nextx;
				y = nexty;
			} time = nexttime time nexttime x = nextx x nextx y = nexty y nexty {
				ans = false;
				break;
			} ans = false ans false break; if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		} ans {
			System.out.println("Yes");
		} System.out.println("Yes") System.out.println System.out System System.out "Yes" {
			System.out.println("No");
		} System.out.println("No") System.out.println System.out System System.out "No" String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

} Main

import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int time = 0;
		int x = 0;
		int y = 0;
		boolean ans = true;
		for(int i = 0; i < n; i++) {
			int nexttime = sc.nextInt();
			int nextx = sc.nextInt();
			int nexty = sc.nextInt();
			int dtime = nexttime - time;
			int dx = Math.abs(nextx - x);
			int dy = Math.abs(nexty - y);
			if(dtime >= dx + dy && dtime % 2 == (dx + dy) % 2) {
				time = nexttime;
				x = nextx;
				y = nexty;
			} else {
				ans = false;
				break;
			}
		}
		if(ans) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}

}
