Question: Implement the findText() method, which has two strings as parameters. The first parameter is the text to be found in the user provided sample text,
Implement the findText() method, which has two strings as parameters. The first parameter is the text to be found in the user provided sample text, and the second parameter is the user provided sample text. The method returns the number of instances a word or phrase is found in the string. In the main() method, prompt the user for a word or phrase to be found and then call findText() in the main() method
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
