If you’re overriding the method equals() of an object, which other method you might also consider?


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More Java Related AllOther Interview Questions

What if I do not provide the string array as the argument to the method?

0 Answers  


what is the package for freshers in valuelabs.

0 Answers  


What is mq in java?

0 Answers  


public class Dog { private int weight; public int getweight(){ return weight; } public void SetWeight(int newWeight){ if (newWeight > 0){ weight = newWeight; } } } public class TestDog { public static void main(String[] args) { Dog d = new Dog(); System.out.println("Dog d's weight is " + d.getWeight()); d.setWeight(42); System.out.println("Dog d's weight is " + d.getWeight()); d.setweight(-42); System.out.println("Dog d's weight is " + d.getWeight()); } } class dog is compiled but there is an error in class TestDog when compiled and the error is with dot notations. I want to kmow why there is error in testdog class when compiled.

3 Answers  


What is stateless object in java?

0 Answers  






What is Map,List,hashtable,ArrayList and difference between them??

0 Answers   Cap Gemini, TCS,


Which method is used to create the daemon thread?

0 Answers  


What is cdi in java?

0 Answers  


What is difference between map and flatmap in java 8?

0 Answers  


Sytem.out.println(" "); this code what mean

2 Answers  


What is the means of java?

0 Answers  


Spring framework ---Can somebody explain me in easily understandable format about AOP, IOC and DI, so that i can explain in interview rather than just telling what is available in net. I am not able to understand that also. I am new to Spring

0 Answers  


Categories