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



Comment Added by : vijay

Comment Added at : 2011-08-21 15:09:41

Comment on Tutorial : equals( ) Versus == in Java By Mashoud
what ll be result for s1==s2 and s1.equals(s2) for following cases?
1)String s1="hello";
String s2="hello";

2)String s1 = new String("Hello");
String s2 = new String("Hello");

3)String s1="hello";
string s2=s1;


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. This is very useful article with clear understandi
View Tutorial          By: Manu Manker at 2014-03-14 05:49:26

2. Hi,

Can anyone suggest a GSM Modem

View Tutorial          By: Archna at 2009-11-06 03:23:14

3. I am not found a J2ME file for playing a audio pla
View Tutorial          By: S.M. ASHIQUER RAHMAN at 2008-11-22 22:33:43

4. Cant undrstand clearly
View Tutorial          By: rathika at 2014-06-09 11:02:16

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

6. So I followed you steps with no compile errors. W
View Tutorial          By: PointLookoutResident at 2014-10-14 19:01:11

7. when i copy paste your program or source code

View Tutorial          By: hello at 2010-07-09 18:56:23

8. i don't use mysql,but oracle.
how to resolv

View Tutorial          By: Mike Zhu at 2009-06-23 19:20:06

9. hey hiii.
at last the progrma has be runnin

View Tutorial          By: jugal at 2009-02-20 08:22:31

10. Guys, txtWeb is back with their National Level Dev
View Tutorial          By: rahul.del at 2012-08-16 10:01:09