Lecture 4
16
Integer arithmetic
•primitive type int (also short, long)
•there are maximum and minimum values
•+, - , * do what you expect them to
•so do >, >= , <, <=, ==
•use () to alter order of operations
•/ truncates:    20/6 is 3
•% (modulus operator) gives remainder:      20 % 6 is 2