On Tue, 2010-10-05 at 15:28 -0400, chris h wrote:

> Benchmark and find out! :)
> 
> What are you using this for? Unless you are doing something crazy it
> probably doesn't matter, and you should pick whichever you feel looks nicer
> / is easier to code in / etc.
> 
> Chris H.
> 
> On Tue, Oct 5, 2010 at 3:23 PM, saeed ahmed <saeed....@gmail.com> wrote:
> 
> > $a = 'hey';
> > $b = 'done';
> >
> > $c = $a.$b;
> > $c = "$a$b";
> >
> > which one is faster for echo $c.
> >


As far as I'm aware, the first of the two will be faster, but only just.
As Saeed mentioned, the difference will be negligible, and unless you
plan to run a line like that in a loop or something hundreds of
thousands of times, you probably won't notice any difference.
Thanks,
Ash
http://www.ashleysheridan.co.uk


Reply via email to