def is_prime(num):
    """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """
    if num == 2:
        return True
    if num < 2 or num % 2 == 0:
        return False

    i = 3
    while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
    return True


if __name__ == '__main__':
    # ??????????????\???
    data = []
    num = int(input())
    for i in range(num):
        data.append(int(input()))
    # data = [6, 2, 3, 4, 5, 6, 7]

    # ?´???°????????°?????????
    num_of_prime = 0
    for d in data:
        if is_prime(d):
            num_of_prime += 1

    # ???????????????
    print('{0}'.format(num_of_prime)) def is_prime(num):
    """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """
    if num == 2:
        return True
    if num < 2 or num % 2 == 0:
        return False

    i = 3
    while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
    return True is_prime """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """ if num == 2:
        return True
     num == 2 num 2 return True True if num < 2 or num % 2 == 0:
        return False

     num < 2 or num % 2 == 0 num < 2 num 2 num % 2 == 0 num % 2 num 2 0 return False False i = 3 i 3 while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
     i <= num**0.5 i num**0.5 num 0.5 if num % i == 0:
            return False
         num % i == 0 num % i num i 0 return False False i += 2 i 2 return True True num num if __name__ == '__main__':
    # ??????????????\???
    data = []
    num = int(input())
    for i in range(num):
        data.append(int(input()))
    # data = [6, 2, 3, 4, 5, 6, 7]

    # ?´???°????????°?????????
    num_of_prime = 0
    for d in data:
        if is_prime(d):
            num_of_prime += 1

    # ???????????????
    print('{0}'.format(num_of_prime)) __name__ == '__main__' __name__ '__main__' data = [] data [] num = int(input()) num int(input()) int input() input for i in range(num):
        data.append(int(input()))
    # data = [6, 2, 3, 4, 5, 6, 7]

    # ?´???°????????°?????????
     i range(num) range num data.append(int(input())) data.append data append int(input()) int input() input num_of_prime = 0 num_of_prime 0 for d in data:
        if is_prime(d):
            num_of_prime += 1

    # ???????????????
     d data if is_prime(d):
            num_of_prime += 1

    # ???????????????
     is_prime(d) is_prime d num_of_prime += 1 num_of_prime 1 print('{0}'.format(num_of_prime)) print '{0}'.format(num_of_prime) '{0}'.format '{0}' format num_of_prime def is_prime(num):
    """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """
    if num == 2:
        return True
    if num < 2 or num % 2 == 0:
        return False

    i = 3
    while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
    return True def is_prime(num):
    """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """
    if num == 2:
        return True
    if num < 2 or num % 2 == 0:
        return False

    i = 3
    while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
    return True is_prime num_of_prime = 0 0 num_of_prime num = int(input()) int(input()) num data = [] [] data num_of_prime += 1 1 num_of_prime
def is_prime(num):
    """ ??°???????´???°????????????????????????
    http://judge.u-aizu.ac.jp/onlinejudge/commentary.jsp?id=ALDS1_1_C
    :param num: ?????????????????°???
    :return: num????´???°??§????????°True
    """
    if num == 2:
        return True
    if num < 2 or num % 2 == 0:
        return False

    i = 3
    while i <= num**0.5:
        if num % i == 0:
            return False
        i += 2
    return True


if __name__ == '__main__':
    # ??????????????\???
    data = []
    num = int(input())
    for i in range(num):
        data.append(int(input()))
    # data = [6, 2, 3, 4, 5, 6, 7]

    # ?´???°????????°?????????
    num_of_prime = 0
    for d in data:
        if is_prime(d):
            num_of_prime += 1

    # ???????????????
    print('{0}'.format(num_of_prime))