whats the difference between == and .equal ?
Answer Posted / deepak sharma
== compares the object refrences to see if they refer to the
same object in memory.
where as
.equals compares the content of object to see if the object
content is same. Most of the times it is used to compare the
String Object. It can be used to compare other Objects too.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
what do you mean by classloader in java?
How to instantiate member inner class?
What is protected access modifier?
what is session in java?
Explain parallel processing in java8?
List out benefits of object oriented programming language?
Can we override private method in java?
Is java developer a good career?
23. Storage space in java is of the form Stack Queue Heap List 24. What is java code embedded in a web page known as Applets Servlets scriptlets snippets 25. Which of the following attributes are compulsory with an
Explain the importance of finalize() method.
Why java applets are more useful for intranets as compared to internet?
How do weakhashmap works?
Which variable is the independent variable?
How do you do absolute value in java?
What is this () in java?