I am an electrical engineering student enrolled in a course for C++ with no prior experience in programming. Our instructor gave my class an assignment to make a C++ program to convert a decimal number to a binary number. This seems like a pretty complex assignment, since he hasn't taught us much thus far. I've been looking through our text book and my notes and feel a bit overwhelmed. Can somebody help me out and instruct me through what exactly I need to do? I don't want just straight up answers, I want to learn and understand. Is there anyone out there that can help me?
Well, first you should write down step by step how you would do it when using just pen and paper.
Then you should try to turn each of these steps into C++ code.
I have prior experience on the actual number conversions, just not any experience with programming :-/ I have all the math written down on paper... but I am at a loss about how to put it into C++ language.
Here's a useful link for you, Jessica: http://www.softwareandfinance.com/Visual_CPP/Decimal_to_Binary.html . It provides a sample source code snippet which is easy to follow. Combining your knowledge of number conversions and the source code within the link, you'll ace the assignment.
... the C++ class I am taking is indeed the introduction course. I don't think the instructor (who is my age... 23) knows how to teach the course at an extremely basic level. I'm sure he knows the subject matter well, but can't relate to students in the same situation I am in. I am trying to make the best of it.
Thank you for your replies and posted links to help me :)