import collections,sys,math,functools,operator,itertools,bisect,heapq,decimal,string,time,random #sys.setrecursionlimit(10**9) #sys.set_int_max_str_digits(0) n,m = map(int,input().split()) x = list(map(int,input().split())) for i in range(m): x[i] *= 10000 c = [list(map(int,input().split())) for i in range(n)] s = set() for i in range(n): z = [] for j in range(m): z.append(1 * c[i][-1] * c[i][j]) s.add(tuple(z)) for i in range(n): if 100 - c[i][-1] == 0: cnt = 0 for j in range(m): if x[j] == 100 * c[i][j] * c[i][-1]: cnt += 1 else: break if cnt == m: print('Yes') exit() continue z = [] for j in range(m): z.append(1 * c[i][-1] * c[i][j]) s.discard(tuple(z)) y = [] for j in range(m): y.append(x[j] - 100*c[i][-1]*c[i][j]) check = 1 for j in range(m): if y[j] % (100 - c[i][-1]) != 0: check = 0 break else: y[j] //= (100 - c[i][-1]) if check == 0: continue #print(i,y,s) if tuple(y) in s: exit(print('Yes')) s.add(tuple(z)) print('No')