Need help writing a code for this in java. Thank YOu for the help.
b) Write and test the program code in Java. This problem will produce a program to compare box volumes The program must ask for two boxes The program must calculate the volume difference, and give the following (in order of If there is no difference, display the volumes are the same lf the volume of one is less than twice the other, display that t is-slightly bigger If the volume of one is less than three times the other, display that it is twice If the volume of one is less than four times the other, display that it is "triple If the volume of one is less than five times the other, display that it is quadruple otherwise, display that it is the calculated multiple second box is wrong) format) The program must indicate the larger box (f not same volume) and by how much The program must not display values less than one (eg. The first box is 0.5 times the size of the . The program must calculate and display the appropriate message (including proper dimension Your code also does NOT (YET) need to worry if the user inputs an invalid value for the input . The output of your code must match the samples EXACTLY You can use the Box class that you created in Lab 3 as a starting point (example: invalid length). We will implement this in a future assignment You can (and should) change the tagline Your code must have the following structure: rate dauble length prvate double height public Bo privase Box secondir Assign2 public statc void main(Stringt) pulic Blokdouble, couble, double) public void calcutate Sceso putlic void depla public void Sample Output 1: (Red indicate user entered, black is displayed by the program) Size calculator- we speak volunes Enter first box dimensions Enter length: 1e Enter width: 10 Enter height: 10 Enter second box dimensions Enter length: 20 Enter width: 20 Enter height: 28 First box: 10.0 x 10.0 x 10.0 volume 1000 Second box: 20.e x 20.e x 20.0 volume 8000 The second box is 8 times the size of the first box