hi,
i am appending a
string using
Stringbuffer sb = new StringBuffer();
method 1:
sb.append("name=" + name);
sb.append("age=" + age);
sb.append("addres=" + address);
method 2:
sb.append("name=");
sb.append(name);
sb.append("age=");
sb.append(age);
sb.append("addres=");
sb.append(address);
Is method 2 better than method 1 ??
I suppose yes as in method one first it will do a string concat and then do a append of string buffer
am i right ?? any comments
TIA
Anil