
class Jan23 {
	public static void main(String[] args) {

		int x = 5;
		int y = x++;

		//int y = x;
		//x++;

		System.out.println("y: " + y);
		System.out.println("x: " + x);

		y = -x--;

		System.out.println("y: " + y);
		System.out.println("x: " + x);

		// bad!  x++ = y;
		// bad!  y = (x < 0);

		double f = 2.99999999999999;

		x = (int) f;   // casting
		
		System.out.println("f: " + f);
		System.out.println("x: " + x);

		f = x;

		f = 2.99999;

		x = (int) Math.ceil(f);
		System.out.println("x: " + x);

		char initial = '!';
		x = (int) initial;
		System.out.println("x: " + x);
	

		/* char, short, int, long -
		     all integral types
			(hold whole numbers)
		*/
		
		System.out.print("hello-");
		System.out.printf("hello\n\n");
		
		System.out.printf("This is x [%d] and this is y [%f]\n", x, f);	
		System.out.printf("x: %d\n", x);	

	
	}
}
