You will find a text file named 1994_weekly_gas_averages.txt. the file contains the average gas price for each week in the year 1994. (there are 52 lines in the file. line 1 contains the average price for week 1; line 2 contains the average price for week 2, and so forth.) write a program that reads the gas prices from the file, and calculates the average gas price for each month. (to get the average price for a given month, calculate the average of the average weekly prices for that month.) then, the program should create another file that lists the names of the months, along with each month’s average gas price, sorted from lowest to highest.

Solved
Show answers

Ask an AI advisor a question