def isPrime(n):
    i = 2
    while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
    return True

N = int(input())
cnt = 0

for _ in range(N):
    a = int(input())
    if isPrime(a):
        cnt += 1

print(cnt) def isPrime(n):
    i = 2
    while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
    return True isPrime i = 2 i 2 while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
     i * i <= n i * i i i n if n % i == 0:
            return False
         n % i == 0 n % i n i 0 return False False i += 1 i 1 return True True n n N = int(input()) N int(input()) int input() input cnt = 0 cnt 0 for _ in range(N):
    a = int(input())
    if isPrime(a):
        cnt += 1 _ range(N) range N a = int(input()) a int(input()) int input() input if isPrime(a):
        cnt += 1 isPrime(a) isPrime a cnt += 1 cnt 1 print(cnt) print cnt a = int(input()) int(input()) a def isPrime(n):
    i = 2
    while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
    return True def isPrime(n):
    i = 2
    while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
    return True isPrime cnt = 0 0 cnt N = int(input()) int(input()) N cnt += 1 1 cnt
def isPrime(n):
    i = 2
    while i * i <= n:
        if n % i == 0:
            return False
        i += 1
    
    return True

N = int(input())
cnt = 0

for _ in range(N):
    a = int(input())
    if isPrime(a):
        cnt += 1

print(cnt)