Goldbach's Conjecture states that for any even number ( n ) greater than or equal to 4, there exists at least one pair of prime numbers ( p_1 ) and ( p_2 ) such that ( n = p_1 + p_2 ). While this conjecture has yet to be proved or disproved, your task is to write a program that determines the number of distinct pairs of prime numbers that satisfy this condition for a given sequence of even numbers.
Task
Write a program that takes a sequence of even integers as input and outputs the number of distinct pairs of prime numbers ( (p_1, p_2) ) such that ( n = p_1 + p_2 ) for each input number ( n ). Note that pairs ( (p_1, p_2) ) and ( (p_2, p_1) ) are considered the same and should be counted only once.
Input Format
Each line of input contains a single even integer ( n ).
You may assume that each integer is even, ( n \geq 4 ), and ( n < 215 ).
The end of the input is indicated by a line containing the number 0.
Output Format
For each input number ( n ), output a single line containing the number of distinct pairs of prime numbers that sum to ( n ).
No other characters should appear in the output.
Example
Input
text
6
10
12
0
Output
text
1
2
1
Solution
Implement your solution in the /app/ directory.
Important: place your implementation at /app/solution.py so the verifier can run it.