9. (A) An Integer cannot be cast to a String. Don’t confuse this with
System.out.println(intObj.toString()); 9
Note that if the first line of the code fragment were
Integer intObj = new Integer(9);
then the error would be detected at compile time.
//outputs