Modify the class written for exercise 9a to include the


a. Modify the class written for Exercise 9a to include the grade of gas. Assume there are three grades of gas: 87 octane, 93 octane, and 97 octane.

b. Include the class written for Exercise 10a in a program that simulates the arrival of 10 customers (using a while loop). The arrival time, number of gallons of gas each customer requests, and octane rating of the gas should be displayed. After the last customer, your program should display the total number of gallons requested for each grade of gas.

c. What does your simulation assume about the comparative desirability of each grade of gas? Is this assumption realistic?

d. Based on your answer to Exercise 10c, what are the implications of using the simulation to determine how much of each grade of gas to supply to a gas station?

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: Modify the class written for exercise 9a to include the
Reference No:- TGS02192043

Expected delivery within 24 Hours