An operator is a type of mathematical function. It represents an action upon an input, in order to deliver an output. The input consists of operands, and the relationship between the operator and operand is known as an operation. In computer programming, there are many operators that allow the manipulation of data in terms of quantity, structure, space and change.
Common C64 Operators
In its default state, the C64 allows a programmer access to the high-level language BASIC through the BASIC ROM interpreter. Similarly by use of a machine language monitor, the programmer can access a low-level assembly language. Although there are other languages available to the C64 programmer, the following operators will be referred to only in terms of BASIC and assembly language. The notation (position in the operation) of the operator is critical: in the following tables, prefix means the operator is placed before the operand and infix means the operator is placed between operands. Naturally all opcodes in assembly language are placed prefix, however they are included for completeness and comparison.
Arithmetic operations return a numerical output.
|Decrement||DEC, DEX, DEY||Prefix|
|Increment||INC, INX, INY||Prefix|
Boolean operations return a logical output.
Assignment operations return a replicated output.
|Load||LDA, LDY, LDX||Prefix|
|Store||STA, STY, STX||Prefix|
|Transfer||TAX, TAY, TXS, TXA, TYA, TSX||Prefix|
Relational operations return an associative output.
|Not Equal To||<>||Infix|
|Lesser Than Or Equal To||<=, =<||Infix|
|Greater Than Or Equal To||>=, =>||Infix|
|Compare||CMP, CPX, CPY||Prefix|
Trigonometric operations return a numerical output.
C is 0, although A > 0, but A isn't 1.
If no bracket is in line 20, the logic change and also the result: C is 1, cause A > 0, but if hasn't A=1, it is equal which value has B.