'use strict';

function Main(stdin){
  const input = stdin.trim().split(/\r?\n/g);
  const N = Number(input[0]);
  let A = input[1].split(' ').map(str => Number(str));
  A.sort(((a, b) => a - b));
  let tmpA = A.slice(0);

  for(let i = 0; i < N; i++){
      for(let j = 0; j < tmpA.length; j++){      
        if(tmpA[j]%A[i] === 0 && tmpA[j] !==A[i]) {
            tmpA.splice(j,1);
        }
      }
  }

  for(let k = 0; k < N; k++){
    let firstIndex = tmpA.indexOf(tmpA[k]);
    let lastIndex = tmpA.lastIndexOf(tmpA[k]);
    if(firstIndex !== lastIndex){
        tmpA.splice(firstIndex,lastIndex+1);
    }
  }
  console.log(tmpA.length);
}

// 固定
Main(require("fs").readFileSync("/dev/stdin", "utf8"));