#include <stdio.h>


int main(void){
    unsigned long int n;
    scanf("%ld",&n);

    unsigned long int a[n];
    int ans=0;
    int flag = 1;

    for(int i=0;i<n;i++)  {
        scanf("%ld",&a[i]);
    } 

    for(int i=0;i<n;i++){
        flag = 1;
        for(int j=0;j<n;j++){
            if(a[i]%a[j] == 0 && i!= j){
                flag = 0;
                break;
            }
        }
        if(flag == 1) ans ++;
    }


    printf("%d",ans);

    return 0;
}