#C2588. Sum of Primes
Sum of Primes
Sum of Primes
Given a positive integer (n), compute the sum of all prime numbers less than or equal to (n). A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself. Note that 1 is not considered a prime number.
For example, if (n = 10), the prime numbers are 2, 3, 5, and 7, and their sum is 17.
inputFormat
The input consists of a single integer (n) provided via standard input (stdin).
outputFormat
Output the sum of all prime numbers less than or equal to (n) to standard output (stdout).## sample
10
17