import sys def main(): input = sys.stdin.readline N, X, *YZ = map(int, input().split()) C = (5000, 10000) *A, = map(int, input().split()) for i in range(N): A[i] += 1 for i in range(1, -1, -1): for j in range(N): z = min(YZ[i], (A[j] - 1) // C[i]) A[j] -= z * C[i] YZ[i] -= z A.sort(reverse=True) for j in range(N): if YZ[i] == 0: break if A[j] == 0: break A[j] = 0 YZ[i] -= 1 for i in range(N): if A[i] == 0: continue x = A[i] // 1000 + 1 if x > X: print('No') exit() X -= x print('Yes') if __name__ == '__main__': main()