N = int(input()) A = list(map(int, input().split())) if N >= 22: for i in range(22, N): A[i] = 0 N = 22 num_masks = 1 << N vals = [0] * num_masks for mask in range(1, num_masks): for i in range(N): if mask >> i & 1: vals[mask] += A[i] memo = {} for m1, val in enumerate(vals[1:], start=1): if val in memo: m2 = memo[val] p = m1 & m2 m1 ^= p m2 ^= p for i in range(N): if m1 >> i & 1: A[i] *= -1 elif m2 >> i & 1 == 0: A[i] = 0 print('Yes') print(*A) quit() else: memo[val] = m1 print('No')