Given is a number sequence A of length N.

Find the number of integers i \left(1 \leq i \leq N\right) with the following property:

* For every integer j \left(1 \leq j \leq N\right) such that i \neq j , A_j does not divide A_i.

Constraints

* All values in input are integers.
* 1 \leq N \leq 2 \times 10^5
* 1 \leq A_i \leq 10^6

Input

Input is given from Standard Input in the following format:


N
A_1 A_2 \cdots A_N


Output

Print the answer.

Examples

Input

5
24 11 8 3 16


Output

3


Input

4
5 5 5 5


Output

0


Input

10
33 18 45 28 8 19 89 86 2 4


Output

5

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.Arrays;
import java.util.BitSet;


public class Main {

	public static void main(String[] args) {
		InputStream inputStream = System.in;
		OutputStream outputStream = System.out;
		FastInput in = new FastInput(inputStream);
		PrintWriter out = new PrintWriter(outputStream);
		ABC170D solver = new ABC170D();
		solver.solve(1, in, out);
		out.close();
	}

	static class ABC170D{

		public void solve(int testNum, FastInput in, PrintWriter out) {
			
			int n = in.nextInt();
			int []a = in.nextIntArray(n);
			
			Arrays.sort(a);
			BitSet bs = new BitSet(a[n-1]+1);
			
			for(int i = 1 ; i < n ;i++) {
				if(a[i-1] == a[i]) {
					bs.set(a[i], true);
				}
			}

			for(int i = 0 ; i < n ;i++) {
				for(int j = 2 ;  a[i] * j <= a[n-1] ; j++) {
					bs.set(a[i]*j,true);
				}
			}
			
			int ans = 0;
			
			for(int i = 0 ; i < n ;i++) {
				if(!bs.get(a[i])) {
					ans++;
				}
			}
			
			out.println(ans);
		}
	}
	static class FastInput{
		private final BufferedReader in;
		private String[] buff;
		private int index = 0;
		
		public FastInput(InputStream is) {
			in = new BufferedReader(new InputStreamReader(is));
		}
		String nextLine() {
			try {
				return in.readLine();
			} catch (IOException e) {
				e.printStackTrace();
			}
			return null;
		}
		String next() {
			while (buff == null || index >= buff.length) {
				buff = nextLine().split(" ");
				index = 0;
			}
			return buff[index++];
		}
		int nextInt() {
			return Integer.parseInt(next());
		}
		
		long nextLong() {
			return Long.parseLong(next());
		}
		
		Double nextDouble() {
			return Double.parseDouble(next());
		}
		
		BigInteger nextBigInteger() {
			return new BigInteger(next());
		}
		
		BigDecimal nextBigDecimal() {
			return new BigDecimal(next());
		}
		
		public int[] nextIntArray(final int n) {
			final int[] res = new int [n];
			
			for(int i = 0 ; i < n ;i++) {
				res[i] = nextInt();
			}
			return res;
		}
		
		public long[] nextLongArray(final int n) {
			final long[] res= new long [n];
			
			for(int i = 0 ; i < n ;i++) {
				res[i] = nextLong();
			}
			return res;
		}
		
		public double[] nextDoubleArray(final int n ) {
			final double[] res = new double [n];
			
			for(int i = 0 ; i < n ;i++) {
				res[i] = nextDouble();
			}
			return res;
		}
		
		
		public int[][] nextInt2DArray(final int n , final int m){
			int [][]res = new int [n][m];
			
			for(int i = 0 ; i < n ;i++) {
				for(int j = 0 ; j < m ;j++) {
					res[i][j] = nextInt();
				}
			}
			return res;
		}
		public long[][] nextLong2DArray(final int n , final int m){
			long [][]res = new long [n][m];
			
			for(int i = 0 ; i < n ;i++) {
				for(int j = 0 ; j < m ;j++) {
					res[i][j] = nextLong();
				}
			}
			return res;
		}
		
		public char[][] nextChar2DArray(final int n){
			char [][]res = new char [n][];
			
			for(int i = 0 ; i < n ;i++) {
				String s = next();
				res[i] = s.toCharArray();
			}
			
			return res;
		}
	}
}


