This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
|
cpp:operators [2017/04/10 03:42] gthanos created |
cpp:operators [2017/04/11 05:19] |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ====== Τελεστές ====== | ||
| - | |||
| - | Η προτεραιότητα των τελεστών στη C++ δίνεται από τον παρακάτω πίνακα. | ||
| - | |||
| - | ^ Level | ||
| - | | 1 | Scope | :: | scope qualifier | ||
| - | | 2 | Postfix (unary) | ||
| - | | ::: | ::: | () | functional forms | ::: | | ||
| - | | ::: | ::: | [] | subscript | ||
| - | | ::: | ::: | . -> | member access | ::: | | ||
| - | | 3 | Prefix (unary) | ++ -- | prefix increment / decrement | Right-to-left | | ||
| - | | ::: | ::: | ~ ! | bitwise NOT / logical NOT | ::: | | ||
| - | | ::: | ::: | + - | unary prefix | ::: | | ||
| - | | ::: | ::: | & * | reference / dereference | ::: | | ||
| - | | ::: | ::: | new delete | ||
| - | | ::: | ::: | sizeof | ||
| - | (type) | ||
| - | 4 Pointer-to-member | ||
| - | 5 Arithmetic: scaling | ||
| - | 6 Arithmetic: addition | ||
| - | 7 Bitwise shift << >> | ||
| - | 8 Relational | ||
| - | 9 Equality | ||
| - | 10 And & bitwise AND Left-to-right | ||
| - | 11 Exclusive or ^ bitwise XOR Left-to-right | ||
| - | 12 Inclusive or | bitwise OR Left-to-right | ||
| - | 13 Conjunction | ||
| - | 14 Disjunction | ||
| - | 15 Assignment-level expressions | ||
| - | >>= <<= &= ^= |= assignment / compound assignment | ||
| - | ?: conditional operator | ||
| - | 16 Sequencing | ||