Operator (Programming)

Programming languages have a set of operators that perform arithmetical operations, and others such as Boolean operations on truth values, and string operators manipulating strings of text. Computers are mathematical devices, but compilers and interpreters require a full syntactic theory of all operations in order to parse formulae involving any combinations correctly. In particular they depend on operator precedence rules, on order of operations, that are tacitly assumed in mathematical writing. Conventionally, the computing usage of "operator" also goes beyond the mathematical usage (for functions). The C programming language, for example also supports operators like &, ++ and sizeof. Operators like sizeof, which are alphanumeric rather than a mathematical symbol or a punctuation character, it is sometimes called a named operator. In certain programming languages, such as PostScript, the use of the word "operator" has more specific meaning, in that an operator is an executable element in the stack. Because operators here are always written postfix, the need for parentheses is redundant as the way objects are taken from the stack ensures correct evaluation. This is an example of Reverse Polish notation. In some programming languages an operator may work with more than one kind of data, (such as in Java where the + operator is used both for the addition of numbers and for the concatenation of strings). Such an operator is said to be overloaded. In languages that support operator overloading by the programmer, such as C++, one can define customized uses for operators; in Prolog, one can also define new operators. Some languages also allow for the operands of an operator to be of different data types, in which case one of them is coerced to the data type of the other, to permit the operation to occur. For example, in Perl 12 + "3.14", causes the text "3.14159" to be coerced to a number and produces the result 15.14.

 

<< PreviousWord BrowserNext >>
little doe river
sensory neuron
edxor
dennis lewiston
red tailed sportive lemur
lier, belgium
u.s. 29th infantry division
march of dimes
2nd field artillery regiment, rca
hoot (comic book)
game neverending
glossary of wwii german military terms
list of people by name: lev
erwin ringel
list of people by name: lep leu
wcfl
evan thornley
smokeless powder
list of people by name: lea led
list of people named le
ingroup bias
jack whyte
politics of queensland
lincoln futura
rogers pass
emergency vehicle
agathe backer grndahl
ontario provincial highway 427
hatchie river
pam dawber
ontario provincial highway 409
nick tahou hots
flash hider
tunagate
yorkdale shopping centre
rumspringa
beatmania iii
edmond c. gruss
choi
wakabayashi hiroyuki
stephen groombridge
loughton tube station
buckhurst hill tube station
in the time of the butterflies (movie)