
Learning objectives for chapter 4 
1  Learn how to use builtin math functions in C++. 
2  Learn how division with whole numbers works. 
3  Learn how to use a whole number where a floating point number is required. 
4  Learn how to roundoff floating point numbers in console output. 
5  Learn what are "code blocks" and how to use them to organize code. 


Learning objective(s) addressed 

1  2  3  4  5 
Exercises 
Rightclick (or controlclick on a Mac) the title to save its PDF to your system. 

4.1 
A Simple Mortgage Calculator, v.1.0 PDF 
X    X  X 
4.2 
About Lighthouses, v.1.0 PDF 
X    X  X 
4.3 
My Savings Plan, v.1.0 PDF 
X    X  X 
4.4 
Division With Whole Numbers PDF 
 X   X  
 
Samples 
Rightclick (or controlclick on a Mac) the title to save its CPP file to your system. 

4.1 
Using int Variables in Math Functions CPP

X   X   
4.2 
Rounding To The Nearest Penny CPP

X    X  
4.3 
Rounding To The Nearest Whole Number CPP

X    X  
4.4 
Turning Floating Point Formatting On And Off CPP

X    X  
 
Videos 

4.1 
Click HERE for a YouTubelike video that shows how to use the builtin math function for square root.
This video is 13 minutes long. It's programming example is done in both C++ and Java, on a Mac.

X  X   X  X 

Code from the chapter in order of their appearance in the text 
