// Program ReadData is a test bed for you to try various // combinations of input statements with different data // configurations. // It determines the cost of a sheet of glass given the // dimensions and the price per square feet of glass. #include #include using namespace std; const int inchesInSqFt = 144; int main () { int length; // measured in inches float width; // measured in inches float price; // sold by square foot float cost; cout << fixed << showpoint; /********************************************************************* * To complete the program, you need to add code right before * or after this block by the following instruction. * * Instruction: * Prompt user to input data for the three variables: * length, width, and price. *********************************************************************/ cout << "Width: " << setw(5) << width << " Length: " << setw(5) << length << " Price: " << setw(6) << setprecision(2) << price << endl; cost = ((width * length) / inchesInSqFt) * price; cout << "The cost of the glass is $" << setw(6) << cost << endl; return 0; }