#include <stdio.h>
#include <stdlib.h>

int main(void) {
	int n,count = 0,result = 0;
	scanf("%d",&n);
	int a[n];
	for(int i=0;i<n;i++){
		scanf("%d",&a[i]);
	}
	for(int i=1;i<=n;i++){
		for(int j=1;j<=n;j++){
			if(i!=j){
				if(a[i-1] % a[j-1]){
					count++;
				}
			}
		}
		if(count == n-1){
			result++;
		}
		count =0;
	}
	printf("%d",result);
}
