OOAD 2017 old paper Solution

Group C Q.no 8 Step 1 public interface Shape { void draw(); } Create an interface. Shape.java Step 2 Create concrete classes implementing the same interface. Rectangle.java public class Rectangle implements Shape { @Override public void draw() { System.out.println(“Inside Rectangle::draw() method.”); } } Square.java public class Square implements Shape { @Override public void draw() { […]

Continue Reading