The Goldbach Conjecture is an unproven problem in mathematics which states that every even natural number greater than 2 is the sum of two prime numbers. Most numbers have more than 1 pair of primes that satisfy this statement. Given an even number greater than 2, list all pairs of primes that add up to this number.
Input Specification
The only line of input is an even integer .
Output Specification
Output every unique pair of primes that add up to the number inputted, each on a new line, formatted with brackets and commas.
Note: Prime pairs should be listed in increasing order of the first prime, and inversely in decreasing order of the second prime.
Sample Input
72
Sample Output
(5, 67)
(11, 61)
(13, 59)
(19, 53)
(29, 43)
(31, 41)
Sample Explanation
The even number 72 is inputted. Each pair of primes that add up to 72 is listed, the primes on the left increasing in order, and the primes on the right decreasing in order.
Comments