#include <iostream>
using namespace std;
static const int N = 100;
int a[N];
int i,n;
int main(){
    cin>>n;
    for (i=0,i<n;i++){
        cin>>a[i];
    }
    int ans=0;
    for (i=0;i<n;i++){
        int j = floor(sqrt(a[i]));
        for (int k=2;k<=j;k++){
            if (a[i]%k == 0){
                break;
            }
            ans++;
        }
    }
    cout<<ans;
    return 0;
}