#include <bits/stdc++.h>
using namespace std;
int n;
int a[105];
int flag[105];
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  int cnt = 0, round = 0;
  while (cnt < n) {
    int minn = 1e9;
    for (int i = 0; i < n; i++) {
      if (flag[i] == 0 && a[i] < minn) {
        minn = a[i];
      }
    }
    for (int i = 0; i < n; i++) {
      if (flag[i] == 0 && a[i] % minn == 0) {
        flag[i] = 1;
        cnt += 1;
      }
    }
    round += 1;
  }
  printf("%d\n", round);
  return 0;
}
