Page 1 of 1

Programming Question

Posted: Mon Aug 22, 2011 8:41 pm
by Shifat
I have a question to ask.... According to the conjecture of Goldbach we can write an even number (>2)..as the sum of two primes, example-8=5+3,90=83+7 etc...... Now I want to write a program using Qbasic (i am novice since).. where I will input an even number greater than 2, and the output will be two primes... I am having a bit problem to make the algorithm,and the sudocode so please help.

Re: Programming Question

Posted: Mon Aug 22, 2011 8:49 pm
by Shifat
Well I submit a way here, please check if it is programmable,
1.Input A
2.P=3
3. Compare- If (A-P) is a prime then N=A-P
print N,P. Goto 6
else go to next step
4. find the next prime form P to A
let the prime is Q
5. P=Q and goto 3
6.end

Re: Programming Question

Posted: Sat Dec 03, 2011 12:00 pm
by amlansaha
i think your alogarithm is correct :)

Re: Programming Question

Posted: Wed Nov 13, 2013 11:22 am
by shayanjameel08
My question is ..Given two arrays, 1,2,3,4,5 and 2,3,1,0,5 find which number is not present in the second array.

Re: Programming Question

Posted: Wed Nov 13, 2013 11:49 am
by Phlembac Adib Hasan
shayanjameel08 wrote:My question is ..Given two arrays, 1,2,3,4,5 and 2,3,1,0,5 find which number is not present in the second array.
One approach can be searching each element of the first array individually in the second array.

Re: Programming Question

Posted: Fri Oct 21, 2016 9:53 am
by Mehedi Mhc
I want to make a desktop app in C or C++. How can I do so? I shall wait for the answer.

Re: Programming Question

Posted: Mon Nov 07, 2016 12:32 pm
by Phlembac Adib Hasan
To write a desktop app, you need to use a framework. I would recommend Qt, a very popular framework. Visit its website: https://www.qt.io/