using System;
using System.Linq;
using System.Collections.Generic;
using System.IO;

namespace atcorder2
{
    class Program
    {
        public static long Read()
        {
            return long.Parse(Console.ReadLine());
        }

        public static long[] Reads()
        {

            return Console.ReadLine().Split().Select(long.Parse).ToArray();
        }

        public static long d(long sx,long sy,long gx,long gy)
        {
            return Math.Abs(gx - sx) + Math.Abs(gy - sy);
        }
      



        static void Main(string[] args)
        {
            var sw = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false };
            Console.SetOut(sw);

            var n = Read();
            var txy = new long[n][];
            for (int i = 0; i <n; i++)
            {
                txy[i] = Reads();
            }

            bool f = true;
            long dis = d(0, 0, txy[0][1], txy[0][2]);
            bool f1 = dis % 2 != txy[0][0] % 2;
            bool f2 = dis > txy[0][0];
            if (f1||f2) f = false;
            for (int i = 0; i < n-1; i++)
            {
                dis = d(txy[i][1], txy[i][2], txy[i + 1][1], txy[i + 1][2]);
                f1 = dis % 2 != (txy[i + 1][0] - txy[i][0]) % 2;
                f2 = dis > txy[i + 1][0] - txy[i][0];
                if (f1||f2) f = false;
            }
            Console.WriteLine(f ? "Yes" : "No");


            Console.Out.Flush();
        }
    }
}


