JAVA OPERATOR II

As promised in my last post, I will be sharing sample codes showing how Java operators behave. I have named the Java classes in the sample codes after the operator class and I also added the result of each operation on the variables.

Sample Class showing Arithmetic Operations:

arithmeticOperators

Continue reading

Advertisements

Java Operators

Java operators are symbols used to command the computer to perform operations on operands. They follow either of the formats shown in the diagram below and are classified into eight different categories which includes Arithmetic, Relational, Logical, Unary, Bitwise and Bit Shift, Assignment Operators.

operator

Continue reading