Multiple Choice
What exception type does the following program throw? public class Test {
Public static void main(String[] args) {
Object o = new Object() ;
String d = (String) o;
}
}
A) ArithmeticException
B) No exception
C) StringIndexOutOfBoundsException
D) ArrayIndexOutOfBoundsException
E) ClassCastException
Correct Answer:

Verified
Correct Answer:
Verified
Q1: Write a method to find the max
Q3: Analyze the following code. class Test {<br>Public
Q4: Write a class named Hexagon that extends
Q5: Which of the following possible modifications will
Q6: What is the output of running the
Q7: What is wrong in the following code?<br>Test
Q9: A subclass inherits _ from its superclass.<br>a.
Q10: The method _ overrides the following method:
Q11: When you implement a method that is
Q11: Analyze the following code: public class Test1