Fundamental to C++ are the concepts of variables and constants. In algebra, a variable represents a quantity that changes or at least has the potential to change, whereas a constant represents something that does not change. This definition also applies in programming. This chapter examines variables and constants and considers their importance to programming. Specifically, this chapter discusses the following topics:
Data and information
Variable and constant data
Data types
Arrays