XYZ interview question

🔹 Core Java 1. What is JVM, JRE, and JDK? Explain the difference. 2. Why is Java platform-independent? 3. What is an abstract class? 4. What is an interface? 5. What is the difference between an abstract class and a concrete class? 6. What is a constructor? What are its types? 7. What is an exception in Java? 8. What are the types of exceptions in Java? 9. How to create a user-defined exception? 10. When does a NullPointerException occur? --- 🔹 Collections 11. What is a Collection in Java? 12. Why use Collection instead of arrays? 13. Difference between Array and ArrayList 14. Difference between Vector and HashSet 15. What is a Map in Java? What are its types? --- 🔹 String & Threads 16. What is a String? Why is String immutable? 17. What is a thread in Java? 18. What is synchronization? --- 🔹 JDBC 19. How to connect a Java application with a database using JDBC? 20. Difference between Statement and PreparedStatement --- 🔹 Java 8 21. What is JDK 1.8? What are its features? --- 🔹 Spring Framework 22. What is IoC container? What are its types? 23. What is Spring Context? 24. What is a Bean in Spring? 25. What is Dependency Injection? 26. What is @Autowired annotation? 27. Difference between BeanFactory and ApplicationContext 28. What is AOP (Aspect-Oriented Programming)? --- 🔹 Hibernate & JPA 29. What is the difference between Hibernate and JPA? --- 🔹 Coding 30. Write code to find the occurrence of each character in a string.