I'll consider writing one. If you want to compare my program with yours, I'll gladly post the code after you post yours. Until then, I won't do your homework for you. As many others have posted, we're glad to help, but don't expect us to do the work for you. Post specific questions to show that you at least tried.
2007-11-30 04:09:40
·
answer #1
·
answered by Jim Maryland 7
·
1⤊
0⤋
I agree with the first poster.
First, you need to clarify the requirements. As stated, the program has no I/O: the two given numbers can be hard-coded, and there's no requirement for the program to tell the rest of the world what it found. Get the input and output straight before you write a line of code: your program is merely a process for turning input into output.
Now, this is a simple matter using "if" statements. The problem statement denotes the two if statements:
Are they equal?
If not, which is greater?
Draw your flowchart. Walk through it for all three branches.
Start coding IPO: input, processing, and output steps.
Write a simple program shell: adapt from your "hello world" or other trivial example.
Insert your IPO into the program. If you have trouble, take it one step at a time: get the input, use it to produce output, then build up the processing one decision at a time.
When you get stuck, come back and post your code here.
Also, please note that it's pretty hard for someone to help you cheat when you haven't clearly specified the problem or the solution domain. The language is likely important for you: if you're taking C++, a solution in FORTRAN I or COBOL wouldn't do much good.
2007-11-30 07:22:48
·
answer #2
·
answered by norcekri 7
·
0⤊
0⤋