I have no clue what you're trying to show with the second block of code. |
That is his real code. There are a lot of errors because he read my post and removed all of the comments, but when he pasted it to his code, he already had some header files in there and the call to main.
@jcoombs
I reposted amchinese's code because I wanted to show how wrong they were. Do not use that code since there are a plethora of issues with it. Even after I corrected all of the compiler errors, there is still a lot of things that you clearly don't understand. We're not here to do your homework for you. We will, however, attempt to aide you with as much help as possible, given that you are making a valiant effort to do this on your own, and given that you're actually reading what we're posting.
With that being said, I know you're new, and I would like to help you so do two things to help me help you.
1) Post your code. You can either copy and paste it here, highlight your code, then press the < > button to the right of the edit box to format your code, or go to pastebin.com or codepad.org and paste your code there. Once you post it online, share the URL to your with use. No formatting is required to post a link here.
2) Explain, in detail, what you want to do, what you have tried to do, and what you're unable to do. Also explain to us anything you're having issues with, and if there is something you don't understand about
your code, myself or someone else will gladly look over it, point out key points on it, and attempt to explain it to you as best as possible.
I look forward to hearing back from you so we can get this completed for you and hopefully teach you somethings in the process.