Shippingcontainer.java
1    package assignment2;
2    
3    import shapes.SRectangle;
4    import java.util.Scanner;
5    
6    public class Shippingcontainer {
7       public static void main(String[] args){
8           Scanner S = new Scanner(System.in);
9           System.out.println("What Width?");
10          int w = S.nextInt();
11          System.out.println("What height?");
12          int h = S.nextInt();
13          System.out.println("What Length?");
14          int l = S.nextInt();
15          System.out.println("So your dimensions for face are " +w +" as your width, " +h+ " as your height, and " +l+ " as your length.");
16          SRectangle face = new SRectangle(l,w);
17          SRectangle key = new SRectangle(face.diagonal(), h);
18          double Distance = key.diagonal();
19          System.out.println("The distance of that key hold "+Distance);
20      }
21   }
22   
23