What's New
- Read Chapter 3 of the textbook
- Programming Lab 1: Sales Tax due Thursday, 2/9
- Test #1 is Thursday, February 16, covering Chapters 1 - 3 (Introduction to Computers and
Programming in C++, as well as Keyboard Input and Mathematical Expressions, and Formatted and File Input/Output)
- Read Chapter 4.
- Practice Problem 4: Bank Charges due Thursday 2/23
Miscellaneous Information:
Assignments:
Class Notes:
Sample Programs:
Chapter 1: Introduction to Computers and Programming
- hello.cpp: Demonstrates simple console output
Chapter 2: Data Types, Output, and Calculations
- firstVars.cpp: Here is an example demonstrating the use of variables in
output.
- date.cpp: Solution to in-class exercise to output today's date, using
at least two integer variables.
- calcDemo.cpp: Here is an example demonstrating how variables and data
types work in calculations.
- Solution to in-class exercise: gradeAverage.cpp using variables
to calculate and output the average of three test grades.
Chapter 3: Expressions and Interactivity
- Echo.cpp: Here is an example demonstrating the use of cstring variables, and
of the cin object for console input.
- name.cpp: Solution to in-class exercise to input user's first name, then
last name, and store them into two separate variables.
- busses.cpp: Solution to in-class exercise with wedding guests on
busses
- nameAverage.cpp: Solution to in-class exercise inputting full name,
averaging grades, outputting to a file
Chapter 4: Decision Structures
- invest.cpp calculates interest on an investment at one of 2
rates
- ages.cpp: Solution to in-class
exercise with simple if-statements
- moreInterest.cpp A version of
the above program, with more if-statements, more interest rates.
- agesThree.cpp: Solution to
in-class exercise with if-else if-else
- BooleanApp.cpp demonstrates Boolean values and
multi-way if-statements
- SwitchGrades.cpp demonstrates switch statements
Last updated: 2/9 12:05pm