### C++ Programs

C++ programs contain many of the same programming statements and constructs as C programs:

- C++ has the same fundamental types (built-in) data types as C, as well as some types that are not built-in to C.
- Like ISO/ANSI C, C++ allows you to declare new type names by using the typedef construct. These new type names are not new types.
- In general, the scope and storage class rules for C also apply in C++.
- C and C++ have the same set of arithmetic and logical operators.

A C++ name can identify any of the following:

- an object
- a function
- a set of functions
- an enumerator
- a type
- a class member
- a template
- a value
- a label

A declaration introduces a name into a program and can define an area of storage associated with that name.

An expression can be evaluated and is composed of operations and operands. An expression ending with a ; ( semicolon) is called a statement. A statement is the smallest independent computational unit. Functions are composed of groups of one or more statements.

A C++ program is composed of one or more functions. These functions can all reside in a single file or can be placed in different files that are linked to each other. In C++, a program must have one and only one non-member function called main().

C++ Support for Object-Oriented Programming

Source for a Simple C++ Program