Question: TO DO: You will be provided with a text file that has a list of ratings (values between 1 and 10) with multiple values on

TO DO: You will be provided with a text file that has a list of ratings (values between 1 and 10) with multiple values on a line and multiple lines. For your testing, just create one with numbers of your choice. You need to write a program named Distribution.java that will read in the data and return a frequency distribution and an average value for the data. NOTE: you must let the user choose the file from a FileDialog box. Do not hard code the path location!

For instance, if the file had the following

1 6 8 7

2 5 8 9 9

3 4

2 3 9 9 8 8 7

10 1 10 10

3

Your program should return

The following is the distribution of values:

1 - 2

2 - 2

3 - 3

4 - 1

5 - 1

6 - 1

7 - 2

8 - 4

9 - 4

10 - 3

The average value was 6.17

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!