Java Interview Questions & Answers for Freshers 2015

java interview

Graduates or Candidates with Good knowledge in Java Language who
are struggling very hard to crack interview and start
their career as java developer can find the most asked
java interview questions here in this article.This Java interview
questions are very specially designed for java freshers.
We will look into more Java interview questions on this
blog in our coming articles.

1)Is Java Platform Dependent or Platform Independent Language ?
A)Java is a platform independent language.

2)What do you mean by Platform Independence in Java
Programming Language?
A)Java Programming Language is “Write Once & Run Anywhere”.
Platform independednt means program written in java language
can be executed on any platform or operating system.
In simple words , “Java is a platform independence language
which is not restricted to a particular platform”.

3)What is the main difference between JVM,JRE & JDK?
A) JVM stands for Java Virtual Machine,which is an abstract machine of
run time environment for the compiled java class files.

JRE stands for Java Runtime Environment.
It is the implementation of JVM and physically exists.

JDK Java Development Kit which contains JRE & development tools.

4)Does Java Programming Language Supports Pointers?
No. Java Doesnt Support Programming Language due to some loop holes.
As we know that pointer is nothing but reference to memory
location.As handling pointers unprofessionally may lead to
memory leaks and reliability issues.So while designing java
programming language developer has taken proper care
in handling memory leaks.

5)Give some major features of Java Programming Language?
A)Java Langauge has many features added to its belt.
Some of them are Object Oriented, Platform Independent,
Robust, Interpreted, Multi-threaded.

6)What is Base Class in Java ?
A base class is a class, in an object-oriented programming language,
from which other classes are derived.

7)What are local variables in java ?
As the name itself suggest the variables are local.
Local varaiables are declared in a block of code like methods,
contructors etc.One more important thing is local variables
must be initialized before accessing them.

8)What is Final Method in Java?
Final Method in Java Language can’t be extended or subclassed.
A final method can’t be overridden when its class is inherited.

9)How many Main Method’s can we have in same Class ?
Only One. If your try to use more than one main method in a program
it won’t compile and display an error that main method is
already defined in the class.

10)Which package in Java is imported by default?
By deafulat java.lang package is imported.You need not give
package declaration.

We will see more java interview questions and Answers in coming
articles with detailed explanation.

Leave a Reply

Your email address will not be published. Required fields are marked *