Arithmetic Operator Prepared by: Jordan Delacruz Rona Mae Dominguez
The operators are symbols which take one or more operands or expressions and carry out arithmetic or logical calculations. Operators Arithmetic operator Relational operator Logical Operator Assignment Operator Conditional Operators Increment & Decrement Operators Bitwise operators  Special operators
Arithmetic Operators Operators that represent mathematical operations which perform numeric computations, for example, adding two numbers or raising the elements of an array to a given power.
+ Operator The addition operator is used to calculate the sum of two numbers.
Example Operand 1 Operand 2 Operator Output 10 20 30
- Operator The subtraction operator is used to find the difference between two numbers or to indicate the negative value of a numeric expression.
Example Operand 1 Operand 2 Operator Output 8 1 7
Example Negation 8
* Operator The multiplication operator is used to calculate the product of two numbers.
Example Operand 1 Operand 2 Operator Output 8 8 64
/ Operator The division operator is used to calculate the quotient of two numbers.
Example Operand 1 Operand 2 Operator Output 8 4 2
^ Operator The exponentiation operator raises a number to the power of an exponent.
Example Operand 1 Operand 2 Operator Output 8 2 64
% Operator The modulus operator divides two integers and returns the integer remainder.
Example Operand 1 Operand 2 Operator Output % mod 8 5 3
Summary

Arithmetic operator

  • 1.
    Arithmetic Operator Preparedby: Jordan Delacruz Rona Mae Dominguez
  • 2.
    The operators aresymbols which take one or more operands or expressions and carry out arithmetic or logical calculations. Operators Arithmetic operator Relational operator Logical Operator Assignment Operator Conditional Operators Increment & Decrement Operators Bitwise operators Special operators
  • 3.
    Arithmetic Operators Operatorsthat represent mathematical operations which perform numeric computations, for example, adding two numbers or raising the elements of an array to a given power.
  • 4.
    + Operator Theaddition operator is used to calculate the sum of two numbers.
  • 5.
    Example Operand 1Operand 2 Operator Output 10 20 30
  • 6.
    - Operator Thesubtraction operator is used to find the difference between two numbers or to indicate the negative value of a numeric expression.
  • 7.
    Example Operand 1Operand 2 Operator Output 8 1 7
  • 8.
  • 9.
    * Operator Themultiplication operator is used to calculate the product of two numbers.
  • 10.
    Example Operand 1Operand 2 Operator Output 8 8 64
  • 11.
    / Operator Thedivision operator is used to calculate the quotient of two numbers.
  • 12.
    Example Operand 1Operand 2 Operator Output 8 4 2
  • 13.
    ^ Operator Theexponentiation operator raises a number to the power of an exponent.
  • 14.
    Example Operand 1Operand 2 Operator Output 8 2 64
  • 15.
    % Operator Themodulus operator divides two integers and returns the integer remainder.
  • 16.
    Example Operand 1Operand 2 Operator Output % mod 8 5 3
  • 17.