January 14th, 2013, 07:07 AM
Goldbach conjecture program
Hi, I'm still in the process of learning C-Sharp (from free internet tutorials) and I'd like to practice my skills by creating a program which recreates Goldbach's conjecture.
I know the direction I am going to take but I am stuck due to my lack of knowledge and experience.
So what I would like to know is: 'How can I make C-sharp list all the numbers which when added return a value equal to the given number. For example, if I give the program, the number 8, I want it to list out '1+7, 2+6, 3+5, 4+4' and so on. Is there a property or method which can do this?
Secondly, again, is there any property or method which will check whether a number is prime or not.
I'm not asking for a complete solution, just some advice or a nudge in the right direction would be great.
Any help would be appreciated.
Click Here to Expand Forum to Full Width
This is a Codeguru.com survey!