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...


when i write
string s1="java";
in one program(application) and
string s2="java";
in another application
on the same jvm will both objects s2,s2 will refer to same
memory location where "java" is stored
in string pool.

Answers were Sorted based on User's Feedback



when i write string s1="java"; in one program(application) and string s2="java&q..

Answer / ss

String s1="java";
String s2="java";
System.out.println(s1.equals(s2)); -->true
System.out.println(s1==s2); --->true

Is This Answer Correct ?    6 Yes 3 No

when i write string s1="java"; in one program(application) and string s2="java&q..

Answer / tj

Yes,They will refer to same memory location..

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More Core Java Interview Questions

Differentiate between array list and vector in java.

0 Answers  


What is difference between hash mapping and hash table?

5 Answers   NDS, Wipro,


Differences between GridLayout and GridBagLayout?

1 Answers  


What is the top class of AWT event hierarchy?

5 Answers  


What is the role of the java.rmi.naming class?

0 Answers  


What is ResourceBundle class?

1 Answers  


How can we get one Interface methods whit out using implementation of interface

1 Answers   Oracle,


What is a function easy definition?

0 Answers  


What do you mean by ordered and sorted in collections in java?

0 Answers  


What is the use of list in java?

0 Answers  


What is bufferedreader in java?

0 Answers  


What is an abstract class and abstract method?

5 Answers  


Categories