const main = (input) => {
  const args = input.trim().split("\n");
  const Ai = args[1]
    .trim()
    .split(" ")
    .map((n) => parseInt(n, 10));

  const isNotDividable = (ai, i) => {
    const Aj = Ai.filter((_, j) => j !== i);
    return Aj.every((aj) => ai % aj !== 0);
  };

  const count = Ai.filter((ai, i) => isNotDividable(ai, i)).filter((b) => b).length;

  console.log(count);
};

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