public class ShapeMain {
public static void main(String[] args) {
Rectangle r1,r2;
Circle c1,c2;
r1 = new Rectangle();
r2 = new Rectangle(10,20);
c1 = new Circle();
c2 = new Circle(30);
r1.print();
r2.print();
c1.print();
c2.print();
}
}
No comments:
Post a Comment