#C13718. Count Unique Primes

    ID: 43287 Type: Default 1000ms 256MiB

Count Unique Primes

Count Unique Primes

You are given a list of integers. Your task is to compute the number of unique prime numbers in the list. A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. Formally, a number ( n ) is prime if and only if it satisfies ( n > 1 ) and for every integer ( d ) with ( 2 \le d \le \sqrt{n} ), ( d ) does not divide ( n ).

Your solution should read input from standard input (stdin) and output the result to standard output (stdout).

inputFormat

The first line contains an integer ( n ) representing the number of elements in the list. The second line contains ( n ) integers separated by spaces.

outputFormat

Print a single integer representing the count of unique prime numbers in the list.## sample

10
2 3 5 7 8 10 11 13 13 3
6