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 Mamo {
    static long mod=1000000007;
    static Reader in=new Reader();
    static List<Integer >G[];
    static StringBuilder Sd=new StringBuilder();
    public static void main(String [] args) {
    	//Dir by MohammedElkady
    	out.append("YES"+"\n");
    	int n=in.nextInt(),x=in.nextInt(),l=524288,sum=0;
    	if(x!=0) {
    	if(n%2==0) {
    		out.append(0+" ");
    		n--;
    		sum=0;
    	}
    	if(x==1)
    	l--;
    	for(int i=1;i<n;i++) {
    		l--;
    		out.append(l+" ");
    		sum^=l;
    		
    	}
    	out.append((sum^x)+" ");
    	}
    	else {
    		out=new PrintWriter(new BufferedOutputStream(System.out));
    		if(n==1) {out.append("YES"+"\n");out.append("0 ");}
    		else if(n==2) {out.append("NO");}
    		else if(n%2==0) {out.append("YES"+"\n");
    		if(n%2==0) {
    		  n-=3;
  		    out.append("4 8 12 ");}
  		    l=524288;
  		    for(int i=0;i<n-1;i++) {
  	    		l--;
  	    		out.append(l+" ");
  	    		sum^=l;
  	    	}
  		    out.append((sum^x)+" ");
    		}
    		else {out.append("YES"+"\n");
    			l=524288;
      		    for(int i=0;i<n-1;i++) {
      	    		l--;
      	    		out.append(l+" ");
      	    		sum^=l;
      	    	}
      		    out.append((sum^x)+" ");
    		}
    	}
    	
    	
//    	if(n==1) {out.append(x+" ");}
//    	else if(n%2==1) {
//    		out.append(l+" ");
//    		sum^=l;
//    	}
//    	else if(x!=0||(sum==x&&x==1)){
//    		sum^=0;
//    		out.append(0+" ");
//    		out.append((sum^x)+" ");}
//    	else if(sum==x&&x==1){
//    		
//    		out.append(0+" ");
//    		out.append((sum^x)+" ");
//    	}
//    	else {out=new PrintWriter(new BufferedOutputStream(System.out));
//    		if(n==2) {
//    		out.append("NO");}
//    		else {
//    			sum=0;
//    			out.append("YES"+"\n");
//    		    n-=3;
//    		    out.append("4 8 12 ");
//    		    l=524288;
//    		    for(int i=0;i<n-1;i++) {
//    	    		l--;
//    	    		out.append(l+" ");
//    	    		sum^=l;
//    	    	}
//    		    out.append((sum^x)+" ");
//    		}
//    	}
//    	
    	out.close();
    }
    public static PrintWriter out = new PrintWriter(new BufferedOutputStream(System.out));
    static long gcd(long g,long x){if(x<1)return g;else return gcd(x,g%x);}
    
    static class Reader 
    { 
        private InputStream mIs;private byte[] buf = new byte[1024];private int curChar,numChars;public Reader() { this(System.in); }public Reader(InputStream is) { mIs = is;} 
        public int read() {if (numChars == -1) throw new InputMismatchException();if (curChar >= numChars) {curChar = 0;try { numChars = mIs.read(buf);} catch (IOException e) { throw new InputMismatchException();}if (numChars <= 0) return -1; }return buf[curChar++];} 
        public String nextLine(){int c = read();while (isSpaceChar(c)) c = read();StringBuilder res = new StringBuilder();do {res.appendCodePoint(c);c = read();}while (!isEndOfLine(c));return res.toString() ;} 
        public String s(){int c = read();while (isSpaceChar(c)) c = read();StringBuilder res = new StringBuilder();do {res.appendCodePoint(c);c = read();}while (!isSpaceChar(c));return res.toString();} 
        public long l(){int c = read();while (isSpaceChar(c)) c = read();int sgn = 1;if (c == '-') { sgn = -1 ; c = read() ; }long res = 0; do{ if (c < '0' || c > '9') throw new InputMismatchException();res *= 10 ; res += c - '0' ; c = read();}while(!isSpaceChar(c));return res * sgn;} 
        public int nextInt(){int c = read() ;while (isSpaceChar(c)) c = read();int sgn = 1;if (c == '-') { sgn = -1 ; c = read() ; }int res = 0;do{if (c < '0' || c > '9') throw new InputMismatchException();res *= 10 ; res += c - '0' ; c = read() ;}while(!isSpaceChar(c));return res * sgn;} 
        public double d() throws IOException {return Double.parseDouble(s()) ;}
        public boolean isSpaceChar(int c) { return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1; } 
        public boolean isEndOfLine(int c) { return c == '\n' || c == '\r' || c == -1; } 
        public int[] arr(int n){int[] ret = new int[n];for (int i = 0; i < n; i++) {ret[i] = nextInt();}return ret;}
    }
}
class node implements Comparable<node>{
int f, e;
node(int tt,int ll){
f=tt;e=ll;
}
    @Override
    public int compareTo(node o) {
    return f-o.f;    
    }
}
class FastReader
    {
        BufferedReader br;
        StringTokenizer st;
 
        public FastReader()
        {
            br = new BufferedReader(new
                     InputStreamReader(System.in));
        }
 
        String next()
        {
            while (st == null || !st.hasMoreElements())
            {
                try
                {
                    st = new StringTokenizer(br.readLine());
                }
                catch (IOException  e)
                {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }
 
        int nextInt()
        {
            return Integer.parseInt(next());
        }
 
        long nextLong()
        {
            return Long.parseLong(next());
        }
 
        double nextDouble()
        {
            return Double.parseDouble(next());
        }
 
        String nextLine()
        {
            String str = "";
            try
            {
                str = br.readLine();
            }
            catch (IOException e)
            {
                e.printStackTrace();
            }
            return str;
        }
}
 
class Sorting{
 
 public static int[] bucketSort(int[] array, int bucketCount) {
 
 if (bucketCount <= 0) throw new IllegalArgumentException("Invalid bucket count");
 
 if (array.length <= 1) return array; //trivially sorted
 
 
 
 int high = array[0];
 
 int low = array[0];
 
 for (int i = 1; i < array.length; i++) { //find the range of input elements
 
 if (array[i] > high) high = array[i];
 
 if (array[i] < low) low = array[i];
 
 }
 
 double interval = ((double)(high - low + 1))/bucketCount; //range of one bucket
 
 
 ArrayList<Integer> buckets[] = new ArrayList[bucketCount];
 
 for (int i = 0; i < bucketCount; i++) { //initialize buckets
 
 buckets[i] = new ArrayList();
 
 }
 
 
 
 for (int i = 0; i < array.length; i++) { //partition the input array
 
 buckets[(int)((array[i] - low)/interval)].add(array[i]);
 
 }
 
 
 int pointer = 0;
 
 for (int i = 0; i < buckets.length; i++) {
 
 Collections.sort(buckets[i]); //mergeSort
 
 for (int j = 0; j < buckets[i].size(); j++) { //merge the buckets
 
 array[pointer] = buckets[i].get(j);
 
 pointer++;
 
 }
 
}
 
return array;
 
}
}