Categories: Uncategorized

In 1742, a German amateur mathematician named Christian Goldbach wrote to Leonhard Euler with the following conjecture: Every number greater than 2 can be written as the sum of three prime numbers.

In 1742, a German amateur mathematician named Christian Goldbach wrote to Leonhard Euler with the following conjecture:
Every number greater than 2 can be written as the sum of three prime numbers.
In his conjecture, Goldbach was considering 1 as a prime number. By convention we no longer consider 1 as a prime number. And Euler later modified the conjecture as follows:
Every even number greater than or equal to 4 can be expressed as the sum of two prime numbers.
For example:
8 = 3 + 5
20 = 3 + 17 = 7 + 13
42 = 5 + 37 = 11 + 31 = 13 + 29 = 19 + 23
There is no formal proof of this conjecture. However, we can verify Goldbach’s conjecture in certain ranges. For this programming assignment you are asked to verify Goldbach’s conjecture in a user defined range. You will prompt the user to enter the range and then your program will print out all the even numbers in that range (inclusive of the end points) in the form n = a + b, where a and b are prime numbers and a <= b. Each even number should be on a separate line followed by all possible unique pairs of prime numbers. Your sample output should look like this:
Enter the lower limit: 4
Enter the upper limit: 100
4 = 2 + 2
6 = 3 + 3
8 = 3 + 5
10 = 3 + 7 = 5 + 5
….
….
100 = ….
You will do the following error checking on the input:
Lower limit is equal to or greater than 4
Both lower limit and upper limit are even
Lower limit is strictly less than upper limit
Even if only one of these conditions fails, prompt the user to enter both the limits repeatedly
 
Looking for a Similar Assignment? Order now and Get 10% Discount! Use Coupon Code “Newclient”

The post In 1742, a German amateur mathematician named Christian Goldbach wrote to Leonhard Euler with the following conjecture: Every number greater than 2 can be written as the sum of three prime numbers. appeared first on Superb Professors.

"Order a Custom Paper on Similar Assignment! No Plagiarism! Enjoy 20% Discount"

Superbprofessors

Recent Posts

case study one page case study one page case study one page case study one page case study one page

Case study one page Case study one page Case study one page Case study one…

2 years ago

business calculus quiz

Business Calculus quiz that is 10 questions and has an hour time limit. Must be…

2 years ago

hnif 355 disscussion post

Write a 175- to 265-word response to the following: What constitutes “robust interoperability,” and what…

2 years ago

news briefing quest 2

For this News Briefing Quest task , pick and analyze a U.S. political news article…

2 years ago

acc610 final project milestone two critical element ii analysis of financial statements

ACC 610 Milestone TwoGuidelines and Rubric This is the secondof three milestone assignments that will…

2 years ago

write in complete paragraphs 5 pages

Please answer the questions in the attachment. I have sent you the required materials. Send…

2 years ago