Java - Interview Questions and Answers for 'Outputstream' | Search Java Interview Question - javasearch.buggybread.com
Javasearch.buggybread.com
Share

Search Java Interview Questions


 2137 questions in repository.
 There are more than 200 unanswered questions.
Click here and help us by providing the answer.
Label / Company      Label / Company / Text

   



Interview Questions and Answers for 'Outputstream' - 4 question(s) found - Order By Newest

 Q1. What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?Core Java
Admin
info@buggybread.com
Ans. The Reader/Writer class hierarchy is character-oriented, and the InputStream/OutputStream class hierarchy is byte-oriented

  Sample Code for InputStream

  Sample Code for OutputStream

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   file io   streams   reader class   writer class   inputstream   outputstream   stream  file handling


 Q2. Which is the abstract parent class of FileWriter ?Core Java
Admin
info@buggybread.com
Ans. OutputStreamWriter

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   io   file   fileio   filewriter   outputstreamwriter  file handling


 Q3. Which exceptions should be handled with the following code ?

FileOutputStream fileOutputStream = new FileOutputStream(new File("newFile.txt"));
Admin
info@buggybread.com
Ans. FileNotFoundException

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   io   file   fileio   coding   code   scjp   ocjp   filenotfoundexception   fileoutputstream  file handling


 Q4. Will this code compile fine ?

ObjectOutputStream objectOutputStream = new ObjectOutputStream(new FileOutputStream(new File("newFile.txt")));
Core Java
Admin
info@buggybread.com
Ans. Yes.

 Help us improve. Please let us know the company, where you were asked this question :   

   Like      Discuss      Correct / Improve     java   io   file   fileio   coding   code   objectoutputstream   fileoutputstream   yesno  file handling




Subscribe to Java News and Posts. Get latest updates and posts on Java from Buggybread.com
Enter your email address:
Delivered by FeedBurner



comments powered by Disqus
 

Help us and Others Improve. Please let us know the questions asked in any of your previous interview.

Any input from you will be highly appreciated and It will unlock the application for 10 more requests.

Company Name:
Questions Asked:
         

X Close this

X Close this

Help Us Improve.
Please share your
interview experience.

Company Name:   


Questions Asked: