#include <bits/stdc++.h>
using namespace std;
bool mark[105];
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    int a;
    cin >> a;
    mark[a] = 1;
  }
  int ans = 0;
  for (int i = 1; i <= 100; i++) {
    if (mark[i]) {
      ans++;
      for (int j = i; j <= 100; j += i) mark[j] = 0;
    }
  }
  cout << ans;
  return 0;
}
