Problem: Mahmoud and Ehab are on the third stage of their adventures now. As you know, Dr. Evil likes sets. This time he won't show them any set from his large collection, but will ask them to create a new set to replenish his beautiful collection of sets.

Dr. Evil has his favorite evil integer x. He asks Mahmoud and Ehab to find a set of n distinct non-negative integers such the bitwise-xor sum of the integers in it is exactly x. Dr. Evil doesn't like big numbers, so any number in the set shouldn't be greater than 106.

Input

The only line contains two integers n and x (1 ≤ n ≤ 105, 0 ≤ x ≤ 105) — the number of elements in the set and the desired bitwise-xor, respectively.

Output

If there is no such set, print "NO" (without quotes).

Otherwise, on the first line print "YES" (without quotes) and on the second line print n distinct integers, denoting the elements in the set is any order. If there are multiple solutions you can print any of them.

Examples

Input

5 5


Output

YES
1 2 4 5 7

Input

3 6


Output

YES
1 2 5

Note

You can read more about the bitwise-xor operation here: <https://en.wikipedia.org/wiki/Bitwise_operation#XOR>

For the first sample <image>.

For the second sample <image>.

Solution (in JAVA):

Solution:
import java.util.*;
import java.io.*;

// public class Solution implements Runnable
class Solution implements Runnable
{
	public static void main(String[] args) throws IOException  {
		br=new BufferedReader(new InputStreamReader(System.in));
		nextIntBuffer = new String[0];
		bos = new OutputStreamWriter(new BufferedOutputStream(System.out));
		new Thread(null, new Solution(), "Main", 1<<28).start();
	}

	static BufferedReader br;
	static String nextIntBuffer[];
	static int nextIntBase;
	static OutputStreamWriter bos;
	static int nextInt() {
		return Integer.parseInt(next());
	}

	static long nextLong() {
		return Long.parseLong(next());
	}

	static String next() {
		try{
			if(nextIntBase>=nextIntBuffer.length) {
				nextIntBase =0;
				nextIntBuffer = br.readLine().split(" ");
			}
		}catch(IOException e) {}
		return nextIntBuffer[nextIntBase++];
	}


	static void print (String s)    {try{ bos.write(s);	}catch(IOException e){}}
	static void print (int s)  {try{ bos.write(String.valueOf(s));	}catch(IOException e){}}
	static void print (long s)  {try{ bos.write(String.valueOf(s));	}catch(IOException e){}}
	static void print (double s)  {try{ bos.write(String.valueOf(s));	}catch(IOException e){}}
	static void println (String s)  {try{ print(s); 	bos.write('\n');	}catch(IOException e){}}
	static void println (int s)  {try{ print(s); 	bos.write('\n');	}catch(IOException e){}}
	static void println (long s)  {try{ print(s); 	bos.write('\n');	}catch(IOException e){}}
	static void println (double s)  {try{ print(s); 	bos.write('\n');	}catch(IOException e){}}

		public static <T1 extends Comparable<T1> ,T2 extends Comparable<T2> > Pair<T1,T2> mp(T1 a,T2 b) {
		return new Pair<T1,T2>(a,b);
	}

	int pw=1<<17;
	public void main()  {
		br=new BufferedReader(new InputStreamReader(System.in));
		nextIntBuffer = new String[0];

		int t=1;
		while(t-->0) {
			int n=nextInt();
			int x=nextInt();
			if(n==2 && x==0) {println("NO");continue;}
			println("YES");	
			if(n==1){println(x);continue;}
			if(n==2){println(x+" "+0);continue;}
			ArrayList<Integer> a=new ArrayList<Integer>();
			int xor=0;
			for (int i=1;i<=n-3 ;i++ ) {
				a.add(i);
				xor^=i;
			}

			if(xor!=x)
			{
				a.add(0);
				a.add(pw^xor);
				a.add(pw^x);
			}
			else
			{
				a.add(xor^pw);
				a.add(x^(pw*2));
				a.add(pw^(pw*2));
			}

		for (int i=0;i<a.size() ;i++ ) {
				
		print(a.get(i)+" ");
			}	
		}
	}

	public void run() {
		try
		{
			main();
			bos.flush();
		}catch(IOException e) {
			e.printStackTrace();
		}
	}

	static long pow(long x,long y,long mod)
	{
		if (y==0) return 1; 
		long z=pow(x,y/2,mod)%mod;
		if(y%2==0) return (z*z)%mod;
		else return (((x*z)%mod)*z)%mod;
		
	}

	static long gcd(long q,long d) {
		long x1[]=new long[1];long y1[]=new long[1];
		return  gcd(q,d,x1,y1);
	}
	static long gcd(long q,long d,long x[],long y[]) {
		if(d%q==0) {
			x[0]=1;
			y[0]=0;
			return q;
		}
		long x1[]=new long[1];long y1[]=new long[1];
		long ans = gcd(d%q,q,x1,y1);
		y[0]=x1[0];
		x[0]=y1[0]-(d/q)*x1[0];
		return ans;
	}
	static long Inv(long n,long m) {
		long x[]=new long[1];long y[]=new long[1];
		long g= gcd(n,m,x,y);
		if(g==1) {
			return (x[0]+m)%m;
		}
		return -1;
	}
}

class Pair<T1 extends Comparable<T1>, T2 extends Comparable<T2> > implements Comparable<Pair<T1,T2> > {
	  T1 a;
	  T2 b;
	  public Pair(T1 x, T2 y) {
	    a = x; b = y;
	  }
	  @Override
	  public int compareTo(Pair<T1,T2> other) {
	  	int comp1 = a.compareTo(other.a);
	  	if(comp1!=0)
	  		return comp1;
	    return b.compareTo(other.b);
	}
}