Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
8 views

Java Interview Questions

Uploaded by

s13252417
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Java Interview Questions

Uploaded by

s13252417
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

JAVA INTERVIEW QUESTIONS

BASIC:

1. What is java?
2. What is the difference between platform dependent and independent?
3. Difference between java compiler and C Compiler?
4. Difference between JDK,JRE and JVM
5. Tokens and its types
6. Types of data types
7. Variables and its types?
8. Types of variables based on its scope/Visibility.
9. Characteristics of local, static and non-static variable?
10. What is method?
11. Types of method based on the formal arguments?
12. Difference between formal argument and actual argument.
13. How can you call the method?
14. What is method call statement
15. Different types of decision statement
16. What are the data types that are not allowed in a switch case?
17. How the switch case will work?
18. What is the difference between break and switch?
19. Different type of loop statement.
20. Difference between while loop and do-while loop?
21. How can we make for loop an infinite loop?

OOPs CONCEPTS:

1. Static and static members?


2. What is static variable and its characteristics?
3. What is non-static variable and its characteristics?
4. How will you call the static members?
5. How will you call the non-static members?
6. Difference between static and non-static context.
7. When and how many times the static initializers will execute?
8. When and how many times the non-static initializers will execute?
9. What is class loading process?
10. What is object loading process?
11. What is class?
12. What is an object?
13. What is the purpose of new keyword?
14. What is this and when will you use?
15. What is the purpose of constructor?
16. Difference between this and super?
17. What are the difference principles of OOPs?
18. What is encapsulation?
19. How can you achieve encapsulation?
20. What is data hiding?
21. What is the advantages of data hiding?
22. What is the purpose of getter and setter methods?
23. What is private modifier?
24. What is relationship?
25. Types of relation ship?
26. What is has-a relationship and its types?
27. What is Is-A relationship?
28. What is inheritance and how can you achieve?
29. Difference between extends and implements?
30. Different types of inheritance?
31. Why multiple inheritance is not achieved in java?
32. What is diamond problem?
33. How can you achieve multiple inheritance in java?
34. What is polymorphism and its types?
35. Difference between method overloading and overriding?
36. What is the difference between early binding and late binding?
37. What is abstraction?
38. What is the difference between abstraction and interface?
39. Difference between concrete class and abstract class?
40. Why can we go for interfaces?
41. Difference between final, finalize and finally.
42. What is the difference between protected and private modifier?

OBJECT CLASS:

1. What is the purpose of toString() method?


2. Why should we override toString() method?
3. What is the purpose of equals(Object) method?
4. Why should we override equals(Object) method?
5. What is the purpose of hashCode() method?
6. Why should we override hashCode() method?
7. Difference between equals(Object) and == Operator?

STRING:

1. How can you store the string literals in java?


2. What is the difference between string buffer and string builder?
3. Why we are comparing the String with the help of the equals(Object) method?

EXCEPTION:

1. What is an exception?
2. Difference between checked exceptions and unchecked exception?
3. How can you handle the exception?
4. When can we tell exception is handled?
5. What is exception object propagation?
6. What is the difference between throws and throw?
7. What is the purpose of finally block?

WRAPPER CLASS:

1. What is boxing?
2. What is unboxing?
3. What is the purpose of valueOf();
4. What is autoboxing and auto unboxing?

COLLECTION:

1. What is a collection?
2. What is the difference between a collection and an array?
3. Difference between Comparable and Comparator interface.
4. Difference between ArrayList and LinkedList
5. Difference between iterator and listIterator
6. Difference between List and Set.
7. Difference between ArrayList and Vector.
8. What is a set and its characteristics?
9. What is the difference between TreeSet and HashSet?
10. Difference between LinkedHashSet and LinkedList?
11. What is the difference between HashMap and HashTable?

You might also like