import java.util.Scanner;

public class Main{
    public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
    static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    }
} import java.util.Scanner; Scanner java.util public class Main{
    public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
    static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    }
} Main public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    } main {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    } final int T = 0; T 0 final int X = 1; X 1 final int Y = 2; Y 2 Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = Integer.parseInt(sc.next()); n Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int[][] travel = new int[n][3]; travel new int[n][3] n 3 for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        } {
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        } for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            } int j=0; int j=0; j 0 j<3 j 3 j++ j++ j {
                travel[i][j] = Integer.parseInt(sc.next());
            } {
                travel[i][j] = Integer.parseInt(sc.next());
            } travel[i][j] = Integer.parseInt(sc.next()) travel[i][j] travel[i] travel i j Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc boolean can = true; can true int pt=0 pt 0 px=0 px 0 py=0; py 0 for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        } int i=0; int i=0; i 0 i<n i n i++ i++ i {
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        } {
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        } int d = length(px, py, travel[i][X], travel[i][Y]); d length(px, py, travel[i][X], travel[i][Y]) length px py travel[i][X] travel[i] travel i X travel[i][Y] travel[i] travel i Y int t = travel[i][T] - pt; t travel[i][T] - pt travel[i][T] travel[i] travel i T pt if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            } d>t d t {
                can = false;
                break;
            } can = false can false break; if((t-d)%2==1){
                can = false;
                break;
            } (t-d)%2==1 (t-d)%2 (t-d) t d 2 1 {
                can = false;
                break;
            } can = false can false break; px = travel[i][X] px travel[i][X] travel[i] travel i X py=travel[i][Y] py travel[i][Y] travel[i] travel i Y pt=travel[i][T] pt travel[i][T] travel[i] travel i T if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        } can {
            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 static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    } length {
        return(Math.abs(cx-px)+Math.abs(cy-py));
    } return(Math.abs(cx-px)+Math.abs(cy-py)); (Math.abs(cx-px)+Math.abs(cy-py)) Math.abs(cx-px) Math.abs Math cx-px cx px Math.abs(cy-py) Math.abs Math cy-py cy py int px px int py py int cx cx int cy cy public class Main{
    public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
    static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    }
} public class Main{
    public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
    static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    }
} Main
import java.util.Scanner;

public class Main{
    public static void main(String[] args) {
        final int T = 0;
        final int X = 1;
        final int Y = 2;
        Scanner sc = new Scanner(System.in);
        int n = Integer.parseInt(sc.next());
        int[][] travel = new int[n][3];
        for(int i=0;i<n;i++){
            for(int j=0;j<3;j++){
                travel[i][j] = Integer.parseInt(sc.next());
            }
        }
        boolean can = true;
        int pt=0, px=0, py=0;
        for(int i=0;i<n;i++){
            int d = length(px, py, travel[i][X], travel[i][Y]);
            int t = travel[i][T] - pt;
            if(d>t){
                can = false;
                break;
            }else if((t-d)%2==1){
                can = false;
                break;
            }
            px = travel[i][X]; py=travel[i][Y]; pt=travel[i][T];
        }
        if(can){
            System.out.println("Yes");
        }else{
            System.out.println("No");
        }
    }
    static int length(int px, int py, int cx, int cy){
        return(Math.abs(cx-px)+Math.abs(cy-py));
    }
}