Homework: C++ Homework 1: Outputting variables

Topics covered: Simple variable declarations with primitive datatypes, cin (an iostream member)

Source code: Source Code Available Here

Declaring variables
In this lesson I teach you guys how to declare variables and work with ‘built-in types’ within c++. The proper declaration for a variable in C++ is as follows: Type variableName. The types that were introduced in this lesson were int, and double. Int is an integer number, while double is a number that can contain a floating decimal value.

Last modified: February 26, 2014