HashMap & HashSet are not only one of the frequently used data structures, but also one of the popular interview topics. Q1. How does a HashMap store data? A1. As…
…HashMap & HashSet are not only one of the frequently used data structures, but also one of the popular interview topics. Q1. How does a HashMap store data? A1. As…
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Q1. What are the non-final methods in Java Object class, which are meant primarily for extension? A1. The non-final methods are equals( ), hashCode( ), toString( ), clone( ), and…
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Best Practice: “Classes should be immutable unless there’s a very good reason to make them mutable….If a class cannot be made immutable, limit its mutability as much as possible.” –…
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Covers the power of enumand 3 design patterns that can be applied with the help of enums. Q1. Why is it a best practice to use enums over static final…
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Q1. Which Java interface must be implemented by a class whose instances are transported via a Web service? a. Accessible b. BeanInfo c. Remote d. Serializable A1. Answer is “d”….
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Q1. What are mock objects? A1. Mock objects are used in unit testing to ensure that your tests don’t fail due to volatility of the data changes. There are mocking…
Login Register 100+ Free Java interview FAQs 100+ Free Big Data interview FAQs
Q1. What is the difference between “==” and equals(..) method when comparing 2 objects?
A1.It is important to understand the difference between identity (i.e. ==) comparison, which is a shallow comparison that compares only the object references, and the equals( ) comparison, which is a deeper comparison that compares the object attributes.…