Rectangle r1creates a pointer to a variable of class Rectangle, but
Rectangle r1 = new Rectangle()creates the real thing.
abstract classcan’t be instantiated, it can only be inherited from.
Circleat runtime (and this is how you do inheritance).
Shape s1; s1 = new Circle();
protectedallows sub-classes to access a variable (method), while
abstract public void functionName()in the parent class givves a heads-up that subclasses provide that function.