// CS1101 (AY2007/8 Semester 1)
// Lab 5 Exercise 1
// Lab5Ex1.java (partial code)
// This program uses the MyCuboid class.
// It creates two cuboids, and finds the volume of their common space.
//
// The main() method and the signatures for methods 
// readCuboid() and commonVolume() are given - you should not change them.
//
// Written by: Aaron Tan

import java.util.*;

class Lab5Ex1 {

   //-----------------------------------------------------
   // main method used to test the MyCuboid class
   //-----------------------------------------------------
   public static void main (String [] args)  {

       Scanner scanner = new Scanner(System.in);

       MyCuboid cuboid1 = readCuboid("Enter 1st cuboid: ", scanner);
       MyCuboid cuboid2 = readCuboid("Enter 2nd cuboid: ", scanner);

       System.out.println("1st cuboid: " + cuboid1);
       System.out.println("2nd cuboid: " + cuboid2);

       int volume = commonVolume(cuboid1, cuboid2);
       System.out.println("Volume of common space = " + volume);

   }

   //-----------------------------------------------------
   // Read inputs for a new cuboid
   //-----------------------------------------------------
   public static MyCuboid readCuboid (String prompt, Scanner scan) {

       // fill in the code

   }

   //-----------------------------------------------------
   // Returns the volume of common space of two cuboids
   //-----------------------------------------------------
   public static int commonVolume(MyCuboid cuboid1, MyCuboid cuboid2) {

       // file in the code

   }

}


