Section 2 - Reading
1A.2.1 Reading for This Week - and Every Week
Everything you need to succeed in this course is contained in these modules, this course site, and a reference text which can either be my recommended text or any C++ text you choose. Each week visit the course syllabus to find out what I expect you to read for that week.
1A.2.1.1 Lesson Module Reading
Every week you have at least two modules to read, the A module, and the B module. This week, that means:
- module 1A
- module 1B
Read these modules twice, because that's what it takes to digest the material. However, don't stop there, because there's more...
1A.2.1.3 Handout Modules
In addition to the usual two lesson modules each week, the first couple weeks there are a number of handout modules. These appear either near the beginning or the end of the modules list. Check the Course Schedule to see which handout modules are required each week. I'll give you a hand and list the required handouts for this week, but starting next week, you'll need to get that information from the Course Schedule module. This week, in addition to the two lesson modules, read:
- Syllabus
- Resource 1R
1A.2.2 Try Out Every Program On Your Compiler
In most pages, you'll see programs or code fragments. They will be in blocks like this:
cout << "Hello World\n";
You can and should select the code with your mouse, copy it and paste it into a program in your IDE. Compile and run it, to see what it does.
Sometimes, the code won't fit completely into the code box on my web pages, in which case you will see scroll bars:
#include <iostream> using namespace std; int main() { int someNumber; someNumber = -7; someNumber = (someNumber - 2) / 3; cout << "The final value of someNumber: " << someNumber << endl; // just some more stuff to demo / and % cout << "\n-7 divided by 2 is " << (-7 / 2) << endl; cout << "\n-7 mod 2 is " << (-7 % 2) << endl; return (0); }
If that happens, simply select all the code inside that box and paste it into your C++ IDE or text editor to examine it fully.
Either way, I expect you to compile and run the samples as you read the modules. Ask questions if you don't understand the behaviour of the code when you run it. Do this before looking at the assignment for that week.
Exception: During the first week only, do not try to compile anything until you have read module 1B and have successfully followed the instructions on running your first program.
1A.2.1.2 Textbook Reading
I do not absolutely require textbook reading. In fact, if you are having trouble or are confused, the best thing to do is to read only the weekly modules (remember: read them twice), and ask questions here in the forums. However, if you feel you understand the modules pretty well, then you should supplement your understanding by reading the textbook. Read the modules for the current week here at the course site, first, before referring to your text.
The way to read the textbook is to
- read all introductory and early chapters, and
- find the topics covered in the modules, then look up those terms in the textbook index.
1A.2.2 How Reading Relates to Assignments
While it is important to have a good reference like this text, everything you need to do Option A of the assignments is contained in these modules.
Read both modules A and B before attempting the assignment.
Do not even look at the assignment until after you have read the week's modules, twice. Remember, paste and run my examples into your IDE, and make sure you can get them to compile and run. Then, ask question about anything in modules or examples.
If you do not ask me any questions about the modules, then I will assume you understand everything in them.
1A.2.3 Resources for the Entire Course
Here are some reading resources that you can use over the entire quarter.
Recommended Style Booklet
Another source of style information is the recommended booklet, The Elements of C++ Style listed in the syllabus. I recommend that you get that booklet and start to read it.
Web Resources
Besides this lecture and the text, here are some other links that you may find useful:
- General C++ Language Reference: http://www.cplusplus.com/doc/tutorial/
- Microsoft Visual C++ Reference #1: http://msdn.microsoft.com/en-us/library/3bstk3k5
- Microsoft Visual C++ Reference #2: http://msdn.microsoft.com/en-us/library/60k1461a.aspx
These pages may not be useful for a couple weeks, but they will be good ones to bookmark now, while you are getting set up.