-
December 30th, 2010, 01:05 AM
#1
Regarding replace()
Hi ,
I have a string defined, say
String message = "hi there";
I want to replace all the e's with i's,
I can either use message.replace('e','i') or traverse using a for loop and replace all e's with i's.
Can someone tell me the internal working of replace () so that i can understand which is more efficient ??
Thanks a lot
-
December 30th, 2010, 09:49 AM
#2
Re: Regarding replace()
Download the source and look for yourself.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|