Overview
This lab gives you practice with the following java functionalities:
- Java File access using FileWriter.
LEGEND: Keyboard Screen
Task 1: FileLetterCounter
Write a program that asks the user to enter the name of a file, and then ask 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 some files to test the program.
- How should your program handle case sensitivity? (E.g., if the user enters 't', will an occurrence of 'T' count?)
- Make sure you test a variety of situations.
Task 2: FileCaseConverter
Write a program that asks the user for two file names. The first file should be opened for reading, and the second file open for writing. The porgram should read the contents of the first file, change all characters to lowercase, and store the results in the second file. The second file will be a copy of the first file, except that all the characters will be lowercase. Use Notepad or another text editor to create some files to test the program.
