This is a continuation of Exercise 2 from week 7 practical exercises. Import a copy of the two java files, Expenses.java and ExpensesDemo.java that you developed in Exercise 2 Week 7 into your week 8 project in Eclipse. You should also use the MalonesCones.txt file from week 7 to test this program. A second version of MalonesCones.txt (containing more months) is also provided in the zip file for this week's exercises.
a. Modify your solution to use an array of Expenses objects. That is, each month of data that is read from the file will be stored as an Expenses object in the array. Your array size should be 12 to allow for expenses for up to one year. You cannot assume that there will always be 12 months of values in the file (there may be more or less).
b. The program should create the on-screen report as per part b in week 7 exercise 2 but the report is to be generated by processing the array rather than processing the input file.
c. Add a new method to your program to calculate the average (mean) of monthly Kelevens from the array of Expenses objects. Display the average Keleven as shown in figure 1.
Figure 1: see image.
d. The program should create the text file as per part c in week 7 exercise 2 but this file is to be generated by processing the array rather than processing the input file.
Test the program with different sized files with different sets of numbers. Make sure your code works correctly if the file isn't found, if it exists but doesn't have any data in it, or, if the file has too many values to fit into the array. Your solution must incorporate appropriate methods utilising appropriate parameter passing.