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.
Answer Posted / 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 |
Post New Answer View All Answers
Is java util list serializable?
How many ways can we create the string object?
why Java does not support multiple inheritances?
What is the full meaning of java?
What do you mean by jjs in java8?
What class of exceptions are generated by the java run-time system?
What are the differences between checked exception and unchecked exception?
What is an 8 bit word?
What are the rules for naming an array?
Can you use abstract and final both with a method?
Is string a data type in java?
How do generics work in java?
What is the maximum size of hashmap in java?
What do you mean by local class?
How many bits is a 64 bit byte?