Please join us at the new JavaWorld Q&A Forums. Your existing login will work there. The discussions here are now read-only.


JavaWorld Talkback >> 958763

xen
stranger


Reged: 09/09/07
Posts: 1
String concatenation in 1.6
      09/09/07 08:56 PM

I do not know whether this is a new aspect of 1.5 or 1.6, but I've noticed that when I concatenate two strings using Code:
String s = "abc" + i + "def";

(where i is an integer < 10) the resulting String has array size 7. Also, Code:
new StringBuffer("abc").toString()

will give me a String size 3. So there's no need to use .concat anymore.

Post Extras Print Post   Remind Me!     Notify Moderator


Entire topic
Subject Posted by Posted on
* String concatenation in 1.6 xen 09/09/07 08:56 PM

Extra information
0 registered and 0 anonymous users are browsing this forum.

Moderator:   



Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      UBBCode is enabled

Rating:
Thread views: 4512

Rate this thread

Jump to

Contact us JavaWorld

Powered by UBB.threads™ 6.5.5