C/C++ Operators

The following table lists C and C++ operators by category. Click any operator shown for more information on it.

Scope Resolution: Multiplicative: Logical:
Scope resolution:  :: Multiplication:  * Logical-AND:  &&
Postfix: Division:  / Logical-OR:  ||
Array element:  [ ] Modulus:  % Assignment:
Function call:  ( ) Additive: Assignment:  =
Type cast:  (type) Addition:  + Addition:  +=
Member selection:  . or –> Subtraction:  – Subtraction:  –=
Postfix increment:  ++ Shift: Multiplication:  *=
Postfix decrement:  –– Left shift:  << Division:  /=
Unary: Right shift:  >> Modulus:  %=
Indirection:  * Relational & Equality: Left shift assignment:  <<=
Address of:  & Less than:  < Right shift assignment:  >>=
Logical-NOT:  ! Less than or equal to:  <= Bitwise-AND:  &=
One's complement:  ~ Greater than:  > Bitwise-exclusive-OR:  ^=
Prefix increment:  ++ Greater than or equal to:  >= Bitwise-inclusive-OR:  |=
Prefix decrement:  –– Equal:  == Conditional:
sizeof Not equal:  != Conditional:  ? :
new Bitwise: Pointer to Member:
delete Bitwise-AND:  & Pointer to member:  .* or –>
Comma: Bitwise-exclusive-OR:  ^ Reference:
Comma:  , Bitwise-inclusive-OR:  | Reference:  &