Section 1 - Introduction and Resources
3A.1.1 Overview
Last week we learned the basic rules of C++ programs. We learned how to work with numbers like ints and floats, and we also touched upon individual characters, chars.
Strings
This week we go even deeper, learning more about string data, the non-numeric data type that helps us use natural languages like English, Greek or Chinese, in our programs.
User Input
It's now time to have a conversation with our user, so we will learn to ask the user questions and read answers into our program.
Selection
We will also teach our programs how to "think." By that I mean that our programs will do one thing under certain circumstances, but something entirely different under a different set of circumstances: If it's raining, leave 15 minutes early and take an umbrella. If it's cloudy but dry, leave on time. If it's sunny, call in sick and go to the beach.
This is called selection and we will see it in the form of the if and if/else statements. If you haven't done so already, this week you will begin to feel as though you are really becoming a programmer.
3A.1.2 Assigned Reading
As usual, read the week's modules and paste every code sample into your IDE so you can test and expand upon it. Do this before looking at the assignment. If you want more source material after reading the modules, look up any new terms in your textbook index, and see what it has to say about these things.
Additional Module Readings
Review the Class Schedule , Syllabus and Style Rules briefly every week, so you are reminded of important rules and dates
3A.1.3 Selected Web Resources
Strings
You will find that strings are important and useful in C++. These links are more advanced than you need at this point but they do contain material lacking in the text, and this might be helpful to you if you want to learn more than I have supplied in my lectures. Reading these references is not required.
- http://www.fredosaurus.com/notes-cpp/strings/header-string.html
- http://yolinux.com/TUTORIALS/LinuxTutorialC++StringClass.html
Resources for the Entire Course
Once again, I will remind you about optional resources:
- The Elements of C++ Style listed in the syllabus.
- General C++ Language Reference: http://www.cplusplus.com/doc/tutorial/