Given a text file, input.txt, provide the statement required to open this file with the appropriate I/O stream to be able to read and process this file.

Showing Answers 1 - 1 of 1 Answers

Prakash

  • Apr 8th, 2005
 

FileReader FR = new FileReader("C:/input.txt"); 
BufferedReader reader = new BufferedReader(FR); 
//Used for reading line by line 
while( (reader.readLine())!=null) 

//Write ur logic here 
}

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions