#coding:utf-8

import math



n = int(eval(input()))

prime_count = 0

for i in range(n):

    x = int(eval(input()))

    div = 1

    div_count = 0



    while div <= math.sqrt(x) and div_count < 3:

        if x % div == 0 and div == math.sqrt(x):

             div_count += 1

        elif x % div == 0 and div != math.sqrt(x):

             div_count += 2

        div += 1



    if div_count == 2:

        prime_count += 1



print(prime_count)
#coding:utf-8

import math



def isPrime(n):

    if n == 2:

        return True

    elif n % 2 == 0:

        return False

    else:

        for i in range(3,math.ceil(math.sqrt(n))+1,2):

            if n % i == 0:

                return False

        return True



n = int(eval(input()))

c = 0

for i in range(n):

    if isPrime(int(eval(input()))):

        c += 1



print(c)
# coding:utf-8
import math

n = int(eval(input()))
prime_count = 0
for i in range(n):
    x = int(eval(input()))
    div = 1
    div_count = 0
    while div <= math.sqrt(x) and div_count < 3:
        if x % div == 0 and div == math.sqrt(x):
            div_count += 1
        elif x % div == 0 and div != math.sqrt(x):
            div_count += 2
        div += 1
    if div_count == 2:
        prime_count += 1
print(prime_count)

# coding:utf-8
import math


def isPrime(n):
    if n == 2:
        return True
    elif n % 2 == 0:
        return False
    else:
        for i in range(3, math.ceil(math.sqrt(n)) + 1, 2):
            if n % i == 0:
                return False
        return True


n = int(eval(input()))
c = 0
for i in range(n):
    if isPrime(int(eval(input()))):
        c += 1
print(c)

+ +def isPrime(n): +    if n == 2: +        return True +    elif n % 2 == 0: +        return False +    else: +        for i in range(3, math.ceil(math.sqrt(n)) + 1, 2): +            if n % i == 0: +                return False +        return True + + -prime_count = 0 +c = 0 -    x = int(eval(input())) -    div = 1 -    div_count = 0 -    while div <= math.sqrt(x) and div_count < 3: -        if x % div == 0 and div == math.sqrt(x): -            div_count += 1 -        elif x % div == 0 and div != math.sqrt(x): -            div_count += 2 -        div += 1 -    if div_count == 2: -        prime_count += 1 -print(prime_count) +    if isPrime(int(eval(input()))): +        c += 1 +print(c)