You are given a sequence of numbers *a*<sub class="lower-index">1</sub>, *a*<sub class="lower-index">2</sub>, ..., *a*<sub class="lower-index">*n*</sub>, and a number *m*.

Check if it is possible to choose a non-empty subsequence *a*<sub class="lower-index">*i*<sub class="lower-index">*j*</sub></sub> such that the sum of numbers in this subsequence is divisible by *m*.
The first line contains two numbers, *n* and *m* (1 ≤ *n* ≤ 10<sup class="upper-index">6</sup>, 2 ≤ *m* ≤ 10<sup class="upper-index">3</sup>) — the size of the original sequence and the number such that sum should be divisible by it.

The second line contains *n* integers *a*<sub class="lower-index">1</sub>, *a*<sub class="lower-index">2</sub>, ..., *a*<sub class="lower-index">*n*</sub> (0 ≤ *a*<sub class="lower-index">*i*</sub> ≤ 10<sup class="upper-index">9</sup>).
import sys
from array import array

input = lambda: sys.stdin.buffer.readline().decode().strip()
inp = lambda dtype: [dtype(x) for x in input().split()]
inp_2d = lambda dtype, n: [dtype(input()) for _ in range(n)]
inp_2ds = lambda dtype, n: [inp(dtype) for _ in range(n)]
ceil1 = lambda a, b: (a + b - 1) // b
debug = lambda *x: print(*x, file=sys.stderr)
out = []

n, mod = inp(int)
mem = array('i', [0] * mod)
dp = array('b', [0] * mod)

for i in array('i', inp(int)):
    mem[i % mod] += 1
    dp[i % mod] = 1

for i in range(mod):
    stk = []
    for j in range(mod):
        if dp[j]:
            stk.append((j, 0))

    while stk:
        m, num = stk.pop()
        nm = (m + i) % mod

        if not dp[nm] and num + 1 <= mem[i]:
            stk.append((nm, num + 1))
            dp[nm] = 1

    for j in range(1, mem[i] + 1):
        dp[(i * j) % mod] = 1

print(['no', 'yes'][dp[0]])
