human
A guy named Vasya attends the final grade of a high school. One day Vasya decided to watch a match of his favorite hockey team. And, as the boy loves hockey very much, even more than physics, he forgot to do the homework. Specifically, he forgot to complete his physics tasks. Next day the teacher got very angry at Vasya and decided to teach him a lesson. He gave the lazy student a seemingly easy task: You are given an idle body in space and the forces that affect it. The body can be considered as a material point with coordinates (0.
0.
0). Vasya had only to answer whether it is in equilibrium. "Piece of cake" — thought Vasya, we need only to check if the sum of all vectors is equal to 0. So, Vasya began to solve the problem. But later it turned out that there can be lots and lots of these forces, and Vasya can not cope without your help. Help him. Write a program that determines whether a body is idle or is moving by the given vectors of forces.

Input

The first line contains a positive integer n (1 ≤ n ≤ 100), then follow n lines containing three integers each: the xi coordinate, the yi coordinate and the zi coordinate of the force vector, applied to the body ( - 100 ≤ xi, yi, zi ≤ 100).

Output

Print the word "YES" if the body is in equilibrium, or the word "NO" if it is not.

Examples

Input

3
4 1 7
-2 4 -1
1 -5 -3

Output

NO

Input

3
3 -1 7
-5 2 -4
2 -1 -3

Output

YES
Solve the task in PYTHON3.

Give me a Python code to print the word "YES" if the body is in equilibrium, or the word "NO" if it is not?
assistant
#Here is Python code to print the word "YES" if the body is in equilibrium, or the word "NO" if it is not.

# Generated by Haxe 3.4.2
# coding: utf-8

import math as python_lib_Math
import math as Math
from os import path as python_lib_os_Path
import inspect as python_lib_Inspect
import os as python_lib_Os
import functools as python_lib_Functools
try:
    import msvcrt as python_lib_Msvcrt
except:
    pass
import random as python_lib_Random
import subprocess as python_lib_Subprocess
import sys as python_lib_Sys
try:
    import termios as python_lib_Termios
except:
    pass
import time as python_lib_Time
import timeit as python_lib_Timeit
try:
    import tty as python_lib_Tty
except:
    pass

class _hx_AnonObject:
    def __init__(self, fields):
        self.__dict__ = fields

class Enum:
    _hx_class_name = "Enum"
    __slots__ = ("tag", "index", "params")
    _hx_fields = ["tag", "index", "params"]
    _hx_methods = ["__str__"]

    def __init__(self,tag,index,params):
        self.tag = tag
        self.index = index
        self.params = params

    def __str__(self):
        if (self.params is None):
            return self.tag
        else:
            _this = self.params
            return (((HxOverrides.stringOrNull(self.tag) + "(") + HxOverrides.stringOrNull(",".join([python_Boot.toString1(x1,'') for x1 in _this]))) + ")")


class EnumValue:
    _hx_class_name = "EnumValue"

class Physicist:
    _hx_class_name = "Physicist"
    __slots__ = ()
    _hx_statics = ["main"]

    @staticmethod
    def main():
        stdin = Sys.stdin()
        n = Std.parseInt(stdin.readLine())
        x = 0
        y = 0
        z = 0
        i = 0
        while (i < n):
            _this = stdin.readLine()
            coords = list(map(Std.parseInt,_this.split(" ")))
            x = (x + (coords[0] if 0 < len(coords) else None))
            y = (y + (coords[1] if 1 < len(coords) else None))
            z = (z + (coords[2] if 2 < len(coords) else None))
            i = (i + 1)
        result = "NO"
        if (((x == 0) and ((y == 0))) and ((z == 0))):
            result = "YES"
        print(str(result))

class...