An Operator is a symbol that performs operation between
operands.
An operator is said to be unary, if it performs operation
on single operand.
Ex:
int a = 10;
a++;
An operator is said to be binary, if it performs operation
on two operands
Ex:
int a=10,
b=20;
int c = a-b;
An Operator is said to be ternary if it perform operation
on three operands
Ex:
int a = 10,
b=20, c;
c= (a>b) ?
a : b;
Operators in groovy are divided into below categories.
No comments:
Post a Comment