Free Jobs
Reference




click here


click here
Core Java Interview Questions(Basic)

For more advanced and tough Core Java Interview Questions Click Here



Q1. What is the difference between Volatile and Transient Modifiers
a)Volatile: Volatile modifier tells the compiler that the variable can be changed unexpectedly by other parts of the program. b)Transient: Transient modifier tells the compiler that the variable can not be serialized.

Q2. What is the difference between Overloading and overriding
a)overloading: different methods share the same name in the same class.overloading must have different signature for methods. b)overriding:childclass method replaces the parentclass method.overriding must have same signature for methods.

Q3. What is a package
A package is a collection of classes and interfaces which provides access protection and name space management.

Q4. What is java.lang.reflect?
java.lang.reflect is a package that has the ability to analyze itself in runtime. It Provides classes and interfaces for obtaining reflective information about classes and objects

Q5. What is the difference between Integer and int
a)Integer is a class defined in the java.lang package.
b)int is a primitive data type defined in the Java language itself.

Q6. What is Inheritance?
Inheritance is a OOP feature that allows one object acquires the properties of another object. This is a very important concept of object oriented programming because it helps to reduce the code size.

Q7. How is the Assignment differs from Initialization?
Initialization can be done only once however Assignment can be done many times as and when desired.

Q8. How can we allocate memory to an Object?
When an object is created using new operator, memory is allocated for this object as per its size.

Q9. Can you explain the contents of bin and lib in Java Development Kit (JDK)?
Bin has tools like javac, appletviewer etc., whereas lib contains API and all packages.

Q10. Can you expalin passing by value and passing by reference in the context of argument?
a)Passing by value: This method copies the value of an argument into the formal parameter of the function.
b)Passing by reference: This method copies a reference to an argument nto the formal parameter of the function.

For more advanced and tough Core Java Interview Questions Click Here









www.freejobsreference.com Copyright © 2009-2011 | All Rights Reserved
All content of this website is protected by copyright laws and should not be reproduced in any form or by any means without written permission
(Best viewed in IE 8.0+ or Firefox 3.0+ at resolution of 1024 * 768 or higher)