Chapter 2 Flashcards
Arithmetic expression
An expression constructed using arithmetic operators and numbers
Assignment operator
=; assigns whatever is on the right side to the variable on the left side
Associativity
the associativity of arithmetic operators is said to be from left to right
Binary operator
an operator that has two operands
Cast operator
also known as type conversion or type casting - used to explicitly convert one data type to another data type
Character arithmetic
arithmetic operation on char data
Collating sequence
a predefined ordering for the characters in a set
Compound assignment statement
statements that are used to write simple assignment statements in a more concise notation
Computer program
A sequence of statements whose objective is to accomplish a task
Data type
A set of values together with a set of operations
Declaration statements
Statements that are used to declare things, such as variables
Decrement operator
–; decreases the value of a variable by 1
Double precision
Values of type double
Enumeration
A user-defined data type
Executable statements
statements that perform calculations, manipulate data, create output, accept input, and so on
Floating-point
A data type that deals with decimal numbers
Floating-point expression
An expression in which all operands in the expression are floating-point numbers
Floating-point notation
A form of scientific notation used to represent real numbers
Function
A collection of statements; when activated, or executed, it accomplishes something
Identifier
A C++ identifier consists of letters, digits, and the underscore character (_); it must begin with a letter or underscore
Implicit type coercion
When a value of one data type is automatically changed to another data type
Increment operator
++; increases the value of a variable by 1
Initialized
The first time a value is placed in the variable
Input statement
a statement that places data into variables using cin and»_space;