A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
JavaRanch
»
Java Forums
»
Java
»
Java in General
Author
equals method with stringbuffer
mukesh pandey
Greenhorn
Joined: Apr 02, 2010
Posts: 22
posted
Sep 01, 2010 12:28:52
0
StringBuffer
sb1 = new
StringBuffer
("Amit");
StringBuffer
sb2 = new
StringBuffer
("Amit");
why
sb1.equals(sb2) = false ?
while
String
s1 = new String("Amit");
String s2 = new String("Amit");
s1.equals(s2) = true
Vinoth Kumar Kannan
Ranch Hand
Joined: Aug 19, 2009
Posts: 276
I like...
posted
Sep 01, 2010 12:42:50
0
A search in this forum would have helped. We had this topic discussed recently.
http://www.coderanch.com/t/496567/java/java/Difference-equals-method-string-stringbuffer
Please search before posting a question..
OCPJP 6
I agree. Here's the link:
http://ej-technologies/jprofiler
- if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
subject: equals method with stringbuffer
Similar Threads
Difference of equals method in string and stringbuffer
String Q
stringBuffer VS string
String and StringBuffer
String
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter