import strutils, sequtils, math, future, algorithm, nre

type
  si = seq[int]
  ssi = seq[seq[int]]

proc r(): string = stdin.readLine
proc ri(): int = r().parseInt
proc rsi(): seq[int] = r().split.map(parseInt)
proc rn(n: int): seq[string] =
  result = @[]
  for i in 1..n:
    result.add(r())
proc rin(n: int): seq[int] =
  result = @[]
  for i in 1..n:
    result.add(ri())
proc rsin(n: int): seq[seq[int]] =
  result = @[]
  for i in 1..n:
    result.add(rsi())
proc range(x, y: int): seq[int] =
  toSeq(x..y-1)
proc range(x: int): seq[int] =
  toSeq(0..x-1)
proc `:=`[T](l: var T, r: T): T =
  l = r
  l

#=== ここまでテンプレート ===========

proc solve(x: si): bool =
  var tmp = x
  case (tmp := tmp.deduplicate()).len:
    of 3:
      return (tmp[0] xor tmp[1]) == tmp[2]
    of 2:
      return tmp[0] == 0 or tmp[1] == 0
    of 1:
      return tmp[0] == 0
    else:
      return false

discard r()

echo(if rsi().solve(): "Yes" else: "No")