"use strict";

function main(arg) {
    const input = arg.split("\n")
    const N = Number(input[0])
    const A = input[1].split(" ").map(x=>Number(x))

    
    let count = 0
    for(let i = 0; i < N; i++) {
        for(let j = 0; j < N; j++) {
            if(i !== j) {
                if(A[i]%A[j]===0) {
                    count++
                    break
                }
            }
        }
    }
    console.log(N-count)

}

main(require("fs").readFileSync("/dev/stdin", "utf8"));