Question: Write a program that asks the user to enter the name of a file, and then asks the user to enter a character. The program

Write a program that asks the user to enter the name of a file, and then asks the user to enter a character. The program should count and display the number of times that the specified character appears in the file. Use Notepad or another text editor to create a simple file that can be used to test the program.

Step by Step Solution

3.32 Rating (167 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

inputFileName inputEnter name of input file inputFile openinputFileName r printOpening f... View full answer

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 Starting Out With Java From Control Structures Questions!