Computer Science
General Computer Science articles :)
Wednesday, January 28, 2009
Going through a file line by line in java
BufferedReader inFile = new BufferedReader("filename");
String line = null;
try {
while ((line=inFile.readLine())!=null) {
//do something with the line here
}
}
catch (IOException ioe) {
ioe.printStackTrace();
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment