#C4237. Prime Numbers Less Than N

    ID: 47753 Type: Default 1000ms 256MiB

Prime Numbers Less Than N

Prime Numbers Less Than N

Given an integer \(N\), output all prime numbers less than \(N\). A prime number is a natural number greater than 1 that has no divisors other than 1 and itself. Use an efficient algorithm to determine the prime numbers.

If no prime numbers exist, output an empty line.

inputFormat

The input consists of a single integer (N) (0 (\leq) N (\leq 10^5)), read from standard input.

outputFormat

Print all prime numbers less than (N) in ascending order, separated by a single space. If there are no prime numbers, print an empty line.## sample

10
2 3 5 7

</p>