/home/akc/NetBeansProjects/CS1/src/shapes/TheRoom.java
 1 /*
 2  * This program affords opportunities to explore the computational solution to
 3  * simple geometrical problems by means of the construction and use of basic
 4  * shapes.
 5  */
 6 package shapes;
 7 
 8 /**
 9  *
10  * @author akc
11  */
12 public class TheRoom {
13 
14     /**
15      * @param args the command line arguments
16      */
17     public static void main(String[] args) {
18         // GIVEN VALUES
19         double height = 9;
20         double width = 14;
21         double length = 21;
22 
23         // CREATING THE RECTANGLE AND THE KEY
24         SRectangle face = new SRectangle(width, length);
25         SRectangle key = new SRectangle (face.diagonal(),height);
26         double distance = key.diagonal();
27 
28         //PRINT SOLUTION
29         System.out.println("The distance between the two corners of the room is " + distance);
30     }
31 
32 }
33