/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
public class RectangleDemo
{
public static void main(String ab[])
{
// Create a Rectangle object.
Rectangle box = new Rectangle();
// Set length to 10.0 and width to 20.0.
box.setLength(10.0);
box.setWidth(20.0);
// Display the length.
System.out.println("The box's length is " +box.getLength());
// Display the width.
System.out.println("The box's width is " +box.getWidth());
// Display the area.
System.out.println("The box's area is " +box.getArea());
System.out.println("The box's area is " +box.getPerimeter());
}
}