slovodefinícia
increment operator
(foldoc)
increment operator
++
--
decrement operator

A programming language unary operator that
adds one to its operand. Similarly, a decrement operator
subtracts one from its operand.

In the B programming language and its many descendents
(e.g. C, Perl, Java), the increment operator is written
"++" and decrement "--". They can be either prefix or
postfix, both of which return a value as well as changing
their operand. The prefix form, e.g. ++x, increments
variable x before returning its value whereas postfix, x++,
returns x's original value before it was incremented.

The expression ++x is equivalent to the assignment operator,
x += 1. There is no simple corresponding equivalent for x++.
These expressions, ++x, x++, x += 1 are almost equivalent to
the long form x = x + 1 except that the latter involves two
references to x. In the case of a simple variable, this makes
no difference but the operand can be any lvalue (something
that can be assigned to), including a complex pointer
expression whose value changes each time it is evaluated.

If the operand is a pointer then incrementing it (in any of
the above ways) causes it to point to the next element of its
specified type.

The name of the programming language C++ is a humourous use
of the postfix increment operator to imply that C++ is "one
better than" C.

(2019-07-14)
podobné slovodefinícia

Nenašli ste slovo čo ste hľadali ? Doplňte ho do slovníka.

na vytvorenie tejto webstránky bol pužitý dictd server s dátami z sk-spell.sk.cx a z iných voľne dostupných dictd databáz. Ak máte klienta na dictd protokol (napríklad kdict), použite zdroj slovnik.iz.sk a port 2628.

online slovník, sk-spell - slovníkové dáta, IZ Bratislava, Malé Karpaty - turistika, Michal Páleník, správy, údaje o okresoch V4