#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  vector<int> a(n);
  {
    for (auto &e : (a)) cin >> e;
  }
  sort((a).begin(), (a).end());
  vector<int> used(1, a[0]);
  for (auto e : a) {
    bool go = 0;
    for (auto ee : used) {
      if (e % ee == 0) {
        go = 1;
      }
    }
    if (!go) used.push_back(e);
  }
  cout << used.size();
  return 0;
}
