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



Comment Added by : Fins

Comment Added at : 2011-12-14 04:40:09

Comment on Tutorial : equals( ) Versus == in Java By Mashoud
Hi Guys, thanks for sharing this... I have some more doubt.

1. String s1= new String("Hello");
String s2="Hello";

Here, whether s2 will point to the same location as s1?

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

What will be the output of these 2 scenarios?


View Tutorial



Ask a Question

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. Quite Helpful.....
^_^

View Tutorial          By: Alfred_Septio at 2012-09-26 12:38:47

2. is there any way to generate report without seagat
View Tutorial          By: Roshni at 2012-10-01 09:32:41

3. I successfully connect to mysql server using:

View Tutorial          By: Arsalan at 2012-07-09 16:38:49

4. Hi,
I am getting this exception..My modem i

View Tutorial          By: divya at 2008-04-27 04:12:19

5. This is the solution that I also used, however, th
View Tutorial          By: Rob Ingenthron at 2012-07-18 23:06:18

6. hiiiiiiii
View Tutorial          By: venkateshwarreddy suravaram at 2010-04-30 23:57:01

7. I have compiled by keeping all the points in mind
View Tutorial          By: Sweety at 2011-03-09 22:29:18

8. very helpful & gud tutorial...
thanks..

View Tutorial          By: Narpinder Sharma at 2011-06-27 03:12:20

9. voire pluse a des command java
View Tutorial          By: lahcine moubarek at 2009-02-16 01:59:17

10. "I get an error returned saying the SMPT serv
View Tutorial          By: Dennis at 2011-06-24 10:18:10