[Solved]Java Write Test Function Takes File Name Word Parameters Displays Following Two Numbers Nu Q37217108
In java
Write and test a function that takes any file-name and any wordas parameters and displays the following two numbers:
- The number of times the word occurs exactly inthe file.
E.g. if the word is “brain” and the file contains “brain!”, thatdoes NOT count; similarly with “Brain”, “brainpower”, and so on.Only “brain” as a separate word contributes to the count.
(b) The number of times the word occurs in the file,including as part of other words.
However, if the word is lower-case, capitalized versions are NOTcounted, and if the word is capitalized, lower-case versions areNOT counted.
E.g. if the word is “brain”, then “brain!” “brainpower”,“mybrain” and so on all contribute to the count, but “Brain” doesnot.
Expert Answer
Answer to In java Write and test a function that takes any file-name and any word as parameters and displays the following two num… . . .
OR

