def isprime(x):
    if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
    i = 3
    while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
    return True
count = 0
for s in range(int(input())):
    if isprime(int(input())):
        count += 1
print(count) def isprime(x):
    if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
    i = 3
    while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
    return True isprime if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
     x == 2 x 2 return True True elif x < 2 or x%2 == 0:
        return False
     x < 2 or x%2 == 0 x < 2 x 2 x%2 == 0 x%2 x 2 0 return False False i = 3 i 3 while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
     i <= pow(x,1/2) i pow(x,1/2) pow x 1/2 1 2 if x%i == 0:
            return False
         x%i == 0 x%i x i 0 return False False i = i + 2 i i + 2 i 2 return True True x x count = 0 count 0 for s in range(int(input())):
    if isprime(int(input())):
        count += 1 s range(int(input())) range int(input()) int input() input if isprime(int(input())):
        count += 1 isprime(int(input())) isprime int(input()) int input() input count += 1 count 1 print(count) print count count += 1 1 count count = 0 0 count def isprime(x):
    if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
    i = 3
    while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
    return True def isprime(x):
    if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
    i = 3
    while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
    return True isprime
def isprime(x):
    if x == 2:
        return True
    elif x < 2 or x%2 == 0:
        return False
    i = 3
    while i <= pow(x,1/2):
        if x%i == 0:
            return False
        i = i + 2
    return True
count = 0
for s in range(int(input())):
    if isprime(int(input())):
        count += 1
print(count)