Problem: Today Pari and Arya are playing a game called Remainders.

Pari chooses two positive integer x and k, and tells Arya k but not x. Arya have to find the value <image>. There are n ancient numbers c1, c2, ..., cn and Pari has to tell Arya <image> if Arya wants. Given k and the ancient values, tell us if Arya has a winning strategy independent of value of x or not. Formally, is it true that Arya can understand the value <image> for any positive integer x?

Note, that <image> means the remainder of x after dividing it by y.

Input

The first line of the input contains two integers n and k (1 ≤ n, k ≤ 1 000 000) — the number of ancient integers and value k that is chosen by Pari.

The second line contains n integers c1, c2, ..., cn (1 ≤ ci ≤ 1 000 000).

Output

Print "Yes" (without quotes) if Arya has a winning strategy independent of value of x, or "No" (without quotes) otherwise.

Examples

Input

4 5
2 3 5 12


Output

Yes


Input

2 7
2 3


Output

No

Note

In the first sample, Arya can understand <image> because 5 is one of the ancient numbers.

In the second sample, Arya can't be sure what <image> is. For example 1 and 7 have the same remainders after dividing by 2 and 3, but they differ in remainders after dividing by 7.

Solution (in JAVA):

Solution:
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.InputMismatchException;

public class RemaindersGame {
    public static void main(String[] args) {
        FasterScanner sc = new FasterScanner();
        
        int N = sc.nextInt();
        int K = sc.nextInt();
        
        Integer[] primes = SieveOfAtkin.getPrimes(1000);
        CountMap kcm = primeFactor(K, primes);
        
        HashSet<Integer> pfac = new HashSet<Integer>();
        for (int k : kcm.keySet()) {
        	pfac.add(slowPow(k, kcm.getCount(k)));
        }
        
        HashSet<Integer> used = new HashSet<Integer>();
        for (int i = 0; i < N; i++) {
        	int C = sc.nextInt();
        	for (int f : pfac) {
        		if (C % f == 0) {
        			used.add(f);
        		}
        	}
        	for (int f : used) {
        		pfac.remove(f);
        	}
        	used.clear();
        }
        
        System.out.println((pfac.size() == 0) ? "Yes" : "No");
    }
    
    public static int slowPow(int x, int p) {
    	int pow = 1;
    	for (int i = 0; i < p; i++) {
    		pow *= x;
    	}
    	return pow;
    }
    
    public static CountMap primeFactor(int n, Integer[] primes) {
    	CountMap cm = new CountMap();
    	for (int i = 0; i < primes.length; i++) {
    		int p = primes[i];
    		if (p * p > n) {
    			break;
    		}
    		while (n % p == 0) {
    			n /= p;
    			cm.addCount(p, 1);
    		}
    	}
    	if (n > 1) {
    		cm.addCount(n, 1);
    	}
    	return cm;
    }
    
    public static class CountMap extends HashMap<Integer, Integer> {
		private static final long serialVersionUID = 8752116290553236695L;

		public int getCount(int k) {
    		return this.containsKey(k) ? this.get(k) : 0;
    	}
    	
    	public void addCount(int k, int v) {
    		this.setCount(k, this.getCount(k) + v);
    	}
    	
    	public void setCount(int k, int v) {
    		if (v == 0) {
    			this.remove(k);
    		} else {
    			this.put(k, v);
    		}
    	}
    }
    
    /**
     * Sieve of Atkin supposedly calculates primes faster than the Sieve of Eratosthenes.
     * See this page for more details:  http://www.sanfoundry.com/java-program-sieve-of-atkin-algorithm/
     */
    public static class SieveOfAtkin {
    	private static boolean[] calcPrimes(int limit) {
            boolean[] prime = new boolean[limit + 1];
            prime[2] = true;
            prime[3] = true;
            int root = (int) Math.ceil(Math.sqrt(limit));
     
            for (int x = 1; x < root; x++)
            {
                for (int y = 1; y < root; y++)
                {
                    int n = 4 * x * x + y * y;
                    if (n <= limit && (n % 12 == 1 || n % 12 == 5))
                        prime[n] = !prime[n];
                    n = 3 * x * x + y * y;
                    if (n <= limit && n % 12 == 7)
                        prime[n] = !prime[n];
                    n = 3 * x * x - y * y;
                    if ((x > y) && (n <= limit) && (n % 12 == 11))
                        prime[n] = !prime[n];
                }
            }
            
            for (int i = 5; i <= root; i++)
                if (prime[i])
                    for (int j = i * i; j < limit; j += i * i)
                        prime[j] = false;
     
            return prime;
        }
    	
    	public static Integer[] getPrimes(int n) {
    		boolean[] isPrime = calcPrimes(n);
    		ArrayList<Integer> primes = new ArrayList<Integer>();
    		for (int i = 0; i <= n; i++) {
    			if (isPrime[i]) {
    				primes.add(i);
    			}
    		}
    		return primes.toArray(new Integer[0]);
    	}
    }

	public static class FasterScanner {
		private byte[] buf = new byte[1024];
		private int curChar;
		private int numChars;

		public int read() {
			if (numChars == -1)
				throw new InputMismatchException();
			if (curChar >= numChars) {
				curChar = 0;
				try {
					numChars = System.in.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 nextString() {
			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 nextLong() {
			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 int[] nextIntArray(int n) {
			int[] arr = new int[n];
			for (int i = 0; i < n; i++) {
				arr[i] = nextInt();
			}
			return arr;
		}

		public int[] nextIntArray(int n, int offset) {
			int[] arr = new int[n + offset];
			for (int i = 0; i < n; i++) {
				arr[i + offset] = nextInt();
			}
			return arr;
		}

		public long[] nextLongArray(int n) {
			long[] arr = new long[n];
			for (int i = 0; i < n; i++) {
				arr[i] = nextLong();
			}
			return arr;
		}

		public long[] nextLongArray(int n, int offset) {
			long[] arr = new long[n + offset];
			for (int i = 0; i < n; i++) {
				arr[i + offset] = nextLong();
			}
			return arr;
		}

		private boolean isSpaceChar(int c) {
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		private boolean isEndOfLine(int c) {
			return c == '\n' || c == '\r' || c == -1;
		}
	}
}