sudBisht
BAN USER
Comments (4)
Reputation 0
Page:
1
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
0
of 0 vote
how many objects will be created in String temp = "A" + "B" + "C" ; explain your answer in detail.
only 1 object will get created.
String internally used stringbuilder..
in this case ...String temp = "A" + "B" + "C" ;
new StringBuilder().append("A").append("B").append("C").toString();
Comment hidden because of low score. Click to expand.
Comment hidden because of low score. Click to expand.
Page:
1
CareerCup is the world's biggest and best source for software engineering interview preparation. See all our resources.
The Java language provides special support for the string concatenation operator ( + ), and for conversion of other objects to strings. String concatenation is implemented through the StringBuilder(or StringBuffer) class and its append method
- sudBisht May 03, 2014check it out here
"http" + "://docs.oracle.com/javase/7/docs/api/java/lang/String.html"