CS-239: FILE I/O Lab |
![]() |
Objectives: |
To gain practice in
reading data from a file. To gain practice in writing data to a file. To gain practice parsing input. |
Background: |
In this application, you will practice input and output to a file. In this case, you will will read lines from an input file. The lines should be of the form of 3 integers separated by commas. Each line will end with a new line character. If the line contains 3 valid integers, you should write the entire liine out to an output file by the name of good-out.txt. If the line contains anything other than 3 valid integers, you should display the entire line and write the line to a file bad-out.txt. |
Terms: |
Delimiter
- A symbol used to separate tokens in an input stream. Token - One unit of data. |
Materials: |
Testing file: tester.txt Part 1: FilePlay2.java, Util1.java Part 3: part3-out.txt Part 4: part4-out.txt |
Acknowledgment |
Updated 02/03/2009 (nlh/jah)