Tuesday 1 September 2015

Java Interview Questions for Freshers

Dear readers, these Java Interview Questions have been designed especially to get you
acquainted with the nature of questions you may encounter during your interview for the subject
of Java Programming Language. As per my experience, good interviewers hardly planned to ask
any particular question during your interview, normally questions start with some basic concept of
the subject and later they continue based on further discussion and what you answer
.

These are some samples what is in the file:-

Q: What is JAR file?
A: JAR files is Java Archive fles and it aggregates many files into one. It holds Java classes in a
library. JAR files are built on ZIP file format and have .jar file extension.

Q: What is a WAR file?
A: This is Web Archive File and used to store XML, java classes, and JavaServer pages. which is
used to distribute a collection of JavaServer Pages, Java Servlets, Java classes, XML files, static Web
pages etc.

Q: What is NullPointerException?
A: A NullPointerException is thrown when calling the instance method of a null object, accessing or
modifying the field of a null object etc.

Q: What are the ways in which a thread can enter the waiting state?
A: A thread can enter the waiting state by invoking its sleep() method, by blocking on IO, by
unsuccessfully attempting to acquire an object's lock, or by invoking an object's wait() method. It
can also enter the waiting state by invoking its (deprecated) suspend() method.

 To get it : Click Here