Question: In Java Please. Can someone please help me with a java code that asks the user to enter a file name (test.txt) that has random

In Java Please.

Can someone please help me with a java code that asks the user to enter a file name(test.txt) that has random words to find if the random words are in the sentences of another file that is

provided(in this case Example.txt)? After that, it has to returns the number of times each word appeared in the Provided file and provide averages of the numbers each line has based

on the words in the test.txt. Please keep the Java code basic. Thanks.

An example would be in the test.txt file the first word is "is", so it should show that "is" appeared 4 times. And the average number is 2.6666... based on the sentences that have the word "is". The calculation to get this would be : (1 + 4 + 3)/3

Example.txt

1 My name is George Watson.

4 Today is Monday, but tomorrow is Tuesday.

3 Working is tiring,

4 How are you?

2 what are you doing?

test.txt

is

my

today

are

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!