Say you have a clean class like this:
public class A { // Stuff }
And a interface like this:
public interface G { /
This is allowed at compile time, because the Java compiler lets you do this; it assumes you know what you're doing.
However, the JVM figures it out and throws a ClassCastException at runtime.
ClassCastException