Operators in Java, types of Operators in Java, Operators supported by Java
An Operator performs a particular operation on the Operands it is applied on.
Symbols which are used to perform any kind of operations on operands are called Operators for Example---
a=10;
b=20;
c=a+b;
in above equation the a, and c are operands and the (+) symbol is an operator.
Types of Operators in Java :-
Assignment Operators
An Operator performs a particular operation on the Operands it is applied on.
Symbols which are used to perform any kind of operations on operands are called Operators for Example---
a=10;
b=20;
c=a+b;
in above equation the a, and c are operands and the (+) symbol is an operator.
Types of Operators in Java :-
- Assignment Operators
- Arithmetic Operators
- Unary Operators
- Equality Operators
- Relational Operators
- Conditional Operators
- instanceof Operators
- Bitwise Operators
- Shift Operators
Operator | Description | Example |
---|---|---|
= | Assignment | int i=10; int j=i; |
Arithmetic Operators
Operator | Description | Example |
---|---|---|
+ | Addition | int i = 8 + 9; byte b = (byte) 5+4; |
- | Subtractiont | int i = 9 – 4; |
* | Multiplication | int i = 8 * 6; |
/ | Division | int i = 10 / 2; |
% | Remainder | int i = 10 % 3; |
{ 0 comments... read them below or add one }
Post a Comment