Advertisement
Guest User

Untitled

a guest
Jul 20th, 2019
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. /* Arithmetic Operators
  2.  
  3. Here, y = 5;
  4. + Addition (x = y + 2 => 7)
  5.  
  6. - Subtraction (x = y - 2 => 3)
  7.  
  8. * Multiplication (x = y * 2 => 10)
  9.  
  10. / Division (x = y / 2 => 2.5)
  11.  
  12. ~/ Division (x = y ~/ 2 => 2)
  13.  
  14. % Modulus (remainder) (x = y % 2 => 1)
  15.  
  16. ++ Increment (x = ++y => y = 6 | x = 6)
  17. (x = y++ => y = 6 | x = 5)
  18.  
  19. -- Decrement (x = --y => y = 4, x = 4)
  20. (x = y-- => y = 4, x = 5)
  21.  
  22. */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement