import math

def isPrime(num):
    for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
    return num

inputs = []

while True:
    try:
        inputs.append(input())
    except(EOFError):
        break

inputs.pop(0)

print(len([x for x in list(map(isPrime, map(int, inputs))) if x is not None]))
 import math math def isPrime(num):
    for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
    return num isPrime for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
     i range(int(math.sqrt(num)), 1, -1) range int(math.sqrt(num)) int math.sqrt(num) math.sqrt math sqrt num 1 -1 if num % i == 0:
            return None
     num % i == 0 num % i num i 0 return None None return num num num num inputs = [] inputs [] while True:
    try:
        inputs.append(input())
    except(EOFError):
        break True try:
        inputs.append(input())
    except(EOFError):
        break except(EOFError):
        break break inputs.append(input()) inputs.append inputs append input() input inputs.pop(0) inputs.pop inputs pop 0 x for x in list(map(isPrime, map(int, inputs))) if x is not None for x in list(map(isPrime, map(int, inputs))) if x is not None x list(map(isPrime, map(int, inputs))) list map(isPrime, map(int, inputs)) map isPrime map(int, inputs) map int inputs x is not None x None if x is not None x print(len([x for x in list(map(isPrime, map(int, inputs))) if x is not None])) print len([x for x in list(map(isPrime, map(int, inputs))) if x is not None]) len [x for x in list(map(isPrime, map(int, inputs))) if x is not None] inputs = [] [] inputs def isPrime(num):
    for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
    return num def isPrime(num):
    for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
    return num isPrime
import math

def isPrime(num):
    for i in range(int(math.sqrt(num)), 1, -1):
        if num % i == 0:
            return None
    return num

inputs = []

while True:
    try:
        inputs.append(input())
    except(EOFError):
        break

inputs.pop(0)

print(len([x for x in list(map(isPrime, map(int, inputs))) if x is not None]))

