Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is the difference between equals method and ==

Answer Posted / r ramya

== checks the string value
equals for checking the strinhg object
String s1="hai";
String s2=new String("hai");
sop(s1==s2);//false
sop(s1.equals(s2));//true

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why are the objects immutable in java?

974


how does multithreading take place on a computer with a single cpu? : Java thread

1121


Which non-unicode letter characters may be used as the first character of an identifier?

996


Is array an object in java?

944


Can we have more than one package statement in the source file?

1042


How big is a 64 bit float?

1016


What are the different types of data structures in java?

969


Is heap stored in ram?

943


Write a java program that prints all the values given at command-line.

1000


What is thread start?

941


What classes of exceptions may be thrown by a throw statement?

949


What is a priority queue java?

972


Can I learn java without any programming experience?

1024


Can we override constructor in java?

1076


What is the purpose of the System class?

985