Assume that you have a file that contains the weekly average prices for a gallon of gas in the United States for the past 3 years. The data is stored in the file as records. Each record contains the...





    1. Assume that you have a file that contains the weekly average prices for a gallon of gas in the United States for the past 3 years. The data is stored in the file as records. Each record contains the average price of a gallon of gas on a specific date. Each record contains the following fields:



    • The month, stored as an integer. January = 1, February = 2, etc.

    • The day of the month, stored as an integer.

    • The year, stored as an integer.

      • The average price of a gallon of gas on the specified date, stored as a real number, rounded to 3 decimal places.




    Design a program that reads the file and displays the lowest and highest gas prices, as well as the dates for those prices.





Jun 06, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here