Fix graphic objects

Report a typo

Here's a class hierarchy of graphical objects. Unfortunately, it's not correct.

interface Resizable {

    void resize(float scale);

    Resizable() { }
}

abstract class GraphicObject {
    int xPos, yPos;

    abstract void draw();
}

class Rectangle extends GraphicObject {

    // fields and methods

    @Override
    public void resize(float scale) { /* do something */ }
}

class Circle extends GraphicObject {

    // fields and methods

    @Override
    public void resize(float scale) { /* do something */ }
}

What corrections should be made to make the code compile? Choose only necessary steps.

Select one or more options from the list
___

Create a free account to access the full topic