Computer Science
Explain 'Arithmetical Operators' with their types.
Values & Data Types Java
12 Likes
Answer
Arithmetical operators are used to perform common mathematical operations. Operands of Arithmetic operators must be of numeric type. There are two types of Arithmetical operators in Java:
- Unary Arithmetical Operators
These operators work on a single operand. Operators in this category are unary plus (+), unary minus (-), prefix and postfix increment (++) and decrement (--) operators. - Binary Arithmetical Operators
These operators work on two operands. They work in mathematical expressions the same way as they work in algebra. Operators in this category are Addition (+), Subtraction (-), Multiplication (*), Division (/) and Modulus (%).
Answered By
7 Likes