#K61002. Expressible as Sum of Two Primes
Expressible as Sum of Two Primes
Expressible as Sum of Two Primes
Given an integer ( n ), determine whether it can be expressed as the sum of two prime numbers. In other words, check if there exist primes ( p ) and ( q ) such that ( n = p + q ). Note that the smallest possible sum of two primes is ( 2+2=4 ). If ( n < 4 ), the answer is automatically "NO".
Your task is to write a program that reads an integer from standard input (stdin) and outputs "YES" if ( n ) can be expressed as the sum of two primes and "NO" otherwise. The solution should consider the prime numbers accurately using efficient prime-checking methods.
inputFormat
The input consists of a single integer ( n ) (( n \geq 1 )), provided via standard input (stdin).
outputFormat
Output a single line containing "YES" if ( n ) can be represented as the sum of two prime numbers, or "NO" if it cannot.## sample
34
YES