#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1000000007;
const long long INF = 0x3f3f3f3f3f3f3f3f;
const int iNF = 0x3f3f3f3f;
const long long MAXN = 102;
int n, a[MAXN];
vector<int> v;
bool vis[MAXN];
int main() {
  ;
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  for (int i = 0; i < n; i += 1) {
    cin >> a[i];
    v.emplace_back(a[i]);
  }
  sort(v.begin(), v.end());
  int ans = 0;
  for (auto e : v) {
    bool flag = false;
    for (int i = 0; i < n; i += 1) {
      if (!vis[i] && a[i] % e == 0) {
        vis[i] = true;
        flag = true;
      }
    }
    ans += flag;
  }
  cout << ans << '\n';
  return 0;
}
