Java Interview Questions Series is a series of collated videos which covers the top 25 interview questions that are frequently asked in any Java interviews. These questions are usually asked for beginners / freshers who have 0 to 2 years of experience. We have also covered some of the important concepts of java as part of this series so as to the candidate is aware of the java concepts in details to impress the interviewer.
Top 25 Java interview questions:
1. Why is Java popular ?
2. Differences between C++ and Javaa
3. What makes Java platform independent?
4. Explain the concepts of JRE, JDK, and JVM
5. What is Just in-time compiler ?
6. Which class is a superclass of all classes?
7. Explain the syntax of the main method in java
8. Explain Typecasting and its types.
9. Can the main method be overloaded?
10. What is an instanceof keyword?
11. How will you generate random numbers in Java?
12. How would you mark an entity package private in Java?
13. How can you pass multiple arguments to a method on each invocation call?
14. Does constructor return any value?
15. What are the restrictions that are applied to the Java static methods?
16. Can a non-static method be called from inside a static method?
17. Differentiate between break and continue
18. Why is multiple inheritance not supported in java?
19. Difference between Abstraction and encapsulation
20. Explain the difference between an interface and an abstract class? When should you use one or the other?
21. What is Exception Handling? And how important is it to handle exceptions in your program ?
22. If a code block throws more than one exception, how can it be handled?
23. What are the main differences between array and collection?
24. What is the advantage of the generic collection?
25. What is the difference between Array and ArrayList?