The code below leads to an error "interface expected here"
public interface MyInterface extends Thread
{
}
Here an interface is created (MyInterface) and it inherits(extends) the Thread class which is not possible at all. Why? Because an interface can inherit only another interface, not any class. As Thread is a class, it cannot be inherited by any interface.
The code below is correct as the interface...
Read More