import java.util.Scanner object Main extends App { val sc = new Scanner(System.in) val n, k = sc.nextLong val a = Array.fill(n.toInt )(sc.nextInt) var cur = 0; var found = collection.mutable.HashSet(0l) for (i <- 0 until n.toInt) { cur = cur ^ a(i) found += cur } found.find(elem => found.contains(elem ^ k)) match { case Some(x) => println("Yes") case _ => println("No") } }