# Types of Expressions

The latest version of this topic can be found at Types of Expressions.

C++ expressions are divided into several categories:

Primary expressions. These are the building blocks from which all other expressions are formed.

Postfix expressions. These are primary expressions followed by an operator — for example, the array subscript or postfix increment operator.

Expressions formed with unary operators. Unary operators act on only one operand in an expression.

Expressions formed with binary operators. Binary operators act on two operands in an expression.

Expressions with the conditional operator. The conditional operator is a ternary operator — the only such operator in the C++ language — and takes three operands.

Constant expressions. Constant expressions are formed entirely of constant data.

Expressions with explicit type conversions. Explicit type conversions, or "casts," can be used in expressions.

Casting. Type-safe "casts" can be used in expressions.

Run-Time Type Information. Determine the type of an object during program execution.