Comment on Tutorial - equals( ) Versus == in Java By Mashoud



Comment Added by : Avnish

Comment Added at : 2010-10-28 04:00:20

Comment on Tutorial : equals( ) Versus == in Java By Mashoud
Ku is quite correct. When you create any object, it goes to the string pool. If you are creating again the same object having different reference variable the jvm directly calls it from the pool. It is the property of jvm not to create replica of objects for overhead. Try it, both are true.

View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. Thanks for good atricle. But this code will always
View Tutorial          By: Binod Suman at 2009-05-28 09:40:48

2. Very very nice example thank you
View Tutorial          By: Fabrice at 2010-12-03 03:36:18

3. Excellent information in simple language. Its wort
View Tutorial          By: Rishi at 2011-11-04 05:03:24

4. hi everybody....

please use comm.j

View Tutorial          By: manoj at 2012-09-24 10:41:34

5. crystal clear explanation
View Tutorial          By: digant at 2009-12-08 09:10:06

6. In the 2nd example ,during the creation on object
View Tutorial          By: priyanka thakur at 2011-08-29 20:24:16

7. its very nice
View Tutorial          By: keerthi at 2012-06-28 17:04:36

8. In good form, don't forget to add column headers a
View Tutorial          By: Jake at 2009-07-13 14:20:16

9. is there a way to notify a specific thread?
View Tutorial          By: bob at 2010-03-23 11:57:29

10. To 25
void *memset( void *buffer, int ch, s

View Tutorial          By: Doniv at 2011-12-15 10:10:52