

/* PART2 Calculator TEST */

public class CalculatorTest {
  public static void main(String[] args) {
    
    /* PART 2 CALCULATOR TEST */
    
    System.out.println(-4 - -4 - -4);
    System.out.println(6 / 4);
    System.out.println(5 % 3);
    System.out.println(-5 % 3);
    System.out.println(Integer.MIN_VALUE);
    System.out.println(Integer.MIN_VALUE - 1); 
    System.out.println(Integer.MAX_VALUE);
    System.out.println(Integer.MAX_VALUE + 1); 
    System.out.println(true && false );
    System.out.println(3 < 5 || 5 < 3);
    System.out.println("It is " + true);
    System.out.println(Math.min(2, Math.max(1, 3)) );
    System.out.println(Math.abs(-2) );
    System.out.println(Math.ceil(-5.1));
    System.out.println(Math.floor(-5.1));
    	// Program output: 
	    /*
	    4
		1 <- because of integer truncation, 6/4 becomes floor(6/4) = floor(1.5) = 1
		2
		-2 
		-2147483648 <-- min integer value
		2147483647  <-- min integer value - 1, numbers are stored in binary, so once we 
					reach the max or min value, the next larger or smaller value wraps
					around the entire range.  Most compilers use two's complement to
					represent integers, whose computation works out to exactly have
					the MAXINT + 1 = MININT or MININT - 1 = MAXINT
		2147483647
		-2147483648
		false
		true
		It is true  <-- This is because we can implicitly convert most primitive types
					to type string by using the '+' or concat symbol as we did in part 1.  
					Thus,("some string" + var) where var is most primitive types will just
					convert var to the string version of that type
		2
		2
		-5.0
		-6.0
	    */
  }
}