import java.util.Scanner;

// C - Traveling
// https://atcoder.jp/contests/abc086/tasks/arc089_a
public class Main {

    /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    }
} import java.util.Scanner; Scanner java.util public class Main {

    /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    }
} Main /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    } main {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = Integer.parseInt(scanner.next()); N Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner int[] T = new int[N]; T new int[N] N int[] X = new int[N]; X new int[N] N int[] Y = new int[N]; Y new int[N] N for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        } {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        } T[i] = Integer.parseInt(scanner.next()) T[i] T i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner X[i] = Integer.parseInt(scanner.next()) X[i] X i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner Y[i] = Integer.parseInt(scanner.next()) Y[i] Y i Integer.parseInt(scanner.next()) Integer.parseInt Integer scanner.next() scanner.next scanner scanner.close() scanner.close scanner int currentX = 0; currentX 0 int currentY = 0; currentY 0 for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        } {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        } int t = T[i]; t T[i] T i int x = X[i]; x X[i] X i int y = Y[i]; y Y[i] Y i int diff = Math.abs(currentX - x) + Math.abs(currentY - y); diff Math.abs(currentX - x) + Math.abs(currentY - y) Math.abs(currentX - x) Math.abs Math currentX - x currentX x Math.abs(currentY - y) Math.abs Math currentY - y currentY y if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            } diff > t diff t {
                // 到達不可
                System.out.println("No");
                return;
            } System.out.println("No") System.out.println System.out System System.out "No" return; int diffT = t - diff; diffT t - diff t diff if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            } diffT % 2 != 0 diffT % 2 diffT 2 0 {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            } System.out.println("No") System.out.println System.out System System.out "No" return; System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args public class Main {

    /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    }
} public class Main {

    /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    }
} Main
import java.util.Scanner;

// C - Traveling
// https://atcoder.jp/contests/abc086/tasks/arc089_a
public class Main {

    /**
     * 最短で移動できるか移動して距離的に可能か、
     * かつ t 時間に指定位置に行けるか (残り時間が偶数か)
     */
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        int N = Integer.parseInt(scanner.next());
        int[] T = new int[N];
        int[] X = new int[N];
        int[] Y = new int[N];

        for (int i = 0; i < N; i++) {
            T[i] = Integer.parseInt(scanner.next());
            X[i] = Integer.parseInt(scanner.next());
            Y[i] = Integer.parseInt(scanner.next());
        }
        scanner.close();

        int currentX = 0;
        int currentY = 0;

        for (int i = 0; i < N; i++) {
            int t = T[i];
            int x = X[i];
            int y = Y[i];

            int diff = Math.abs(currentX - x) + Math.abs(currentY - y);
            if (diff > t) {
                // 到達不可
                System.out.println("No");
                return;
            }

            int diffT = t - diff;
            if (diffT % 2 != 0) {
                // ターン合わせが出来ないので到達不可
                System.out.println("No");
                return;
            }
        }

        System.out.println("Yes");
    }
}
