Algoritma dan Pemrograman Ruang 800 (2)

Operator
Proses value membuat nilai baru
Operand
Variable

Contoh : C=A+B
[ “=” And “+” operators, A,B, & C operands]
Berdasar jumlah operand, operator dibagi menjadi 3 :

Unary Operator > 1 Operand
Binary Operator > 2 Operand
Temary Operator> 3 Operand


Berdasar tipe operasi, operator dibagi menjadi :

Assignment Operator
Logical Operator
Arithmetic Operator
Relational Operator
Bitwise Operator
Pointer Operator


Arithmetic

N ++  :  Post Increament
+ NN :  Pre Increament
N −−  :  Post Decreament
−− N  : Pre Decrement

XOR : Lawan dar fungsi biimplikasi
True + True = False
False False =False
True + False = True
False +True = True

Leave a Reply

Your email address will not be published. Required fields are marked *