Preview:
class shape 
{
    void draw()
    {
        System.out.println("can't say about shape");
    }
}
class square extends shape
{
    @Override
    void draw()
    {
        super.draw();
        System.out.println("shape is square");
    }
}
class B
{
    public static void main(String[] args)
    {
        shape r=new square();
        r.draw();
    }
}
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter