Word Count Assignment
Today we will work on an assignment that reuires knowledge of all the things we have covered till now.
Assignment: Word Counting
Using any text file that has at least 500 words, count the number of words in the file, and count the number of times 'and' appears in the text file regardless of it's case. For the sake of simplicity any token delimted with whitespaces will be considered a word if it has at least 1 alphanumeric character.
Print the word count and the number of times 'and' appears on the system cosole.
Tasks:
1. Create a project in eclipse with a 'src' directory
2. All the code will be put in the src directory
3. Use the package name 'edu.scit.javalab.wordcount'
Grading: 10 marks
1. Coding conventions 2 marks
2. Code quality 3 marks
3. A working program 5 marks
Thursday, January 04, 2007
Wednesday, January 03, 2007
Java I/O Basics
Today we will cover the basics of the Java I/O system. Even though this topic will be covered in detail after 2 weeks, you will need to know enough to be able to read text files and do console I/O.
References:
Today we will cover the basics of the Java I/O system. Even though this topic will be covered in detail after 2 weeks, you will need to know enough to be able to read text files and do console I/O.
References:
- Java Tutorial - I/O Section - check out the character streams and buffered streams
Monday, January 01, 2007
Subscribe to:
Posts (Atom)