given the following code, I have a question:
class A{} class B extends A {} class C extends B{} public class Test { public static void main(String[] args) {
All B's are A's, by inheritance. But not all A's are B's. This particular instance isn't, hence the runtime exception.