#C3149. Sum of Primes Below N
Sum of Primes Below N
Sum of Primes Below N
Given a positive integer \(n\), compute the sum of all prime numbers that are strictly less than \(n\). A prime number is defined as a natural number greater than 1 that has no divisors other than 1 and itself.
Your task is to implement a function or method that, given \(n\), returns the sum of all prime numbers less than \(n\). For example, if \(n=10\), the primes below 10 are 2, 3, 5, and 7, and their sum is 17.
inputFormat
The input consists of a single integer \(n\) (\(0 \leq n \leq 10^6\)), supplied via standard input.
outputFormat
Output a single integer that represents the sum of all prime numbers less than \(n\>.
## sample10
17