#include <math.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#define PI acos(-1)
typedef unsigned long long int ull;
typedef long long int ll;
typedef long double ld;

int main(void) {
  /* 標準入力フラグ */
  int   scan;

  /* 数入力 */
  int    answer;
  int    n;
  int    *a;
  answer = 0;
  scan = scanf("%d", &n);
  a = (int *)malloc(sizeof(int) * n);
  for (int i = 0; i < n; i++) {
    scan = scanf("%d", &a[i]);
  }

  int   *result;
  result = (int *)malloc(sizeof(int) * n);
  /* プログラムを書く */
  for (int i = 0; i < n; i++) {
    result[i] = 1;
    for (int j = 0; j < n; j++) {
      if (i != j && a[i] % a[j] == 0) { 
        result[i] = 0;
      }
    }
  }


  for (int i = 0; i < n; i++) {
    answer += result[i];
  }
  printf("%d", answer);

  return (0);
}

