CSCI 201 Homework Assignment 2

time due submission file
8:00 AM Saturday 25 September, 2004 csci/201/HW2/concrete.java

The task

Write a Java program that computes the cost of paving a driveway. Your main routine should start by giving values for (1), the width of the driveway in feet; (2), the length of the driveway in feet; (3), the depth of the driveway in inches; and (4), the cost of concrete in cubic yards. You do not input these values from the terminal. You just define them in the program with code similar to:

    int width = 12 ;
    int length = 100 ;
    int depth = 5 ;
    double cost = 7.00 ;   /* I got no idea what an yard of concrete costs */

The program should then print the total cost of the concrete for the driveway. By the way, the total cost is:
width * length * depth * cost / 324

Be sure that the class name for your program is concrete and that your program is stored in the file concrete.java.