warning feature in using "&" operator
Lee woo seob writes:
> for i=1 to 10000 do
> a=a&j a=a&k -- fast
> end for
> a=a&(j&k) -- huge time consuming. becomes more severe as
-- the size of "a" increases.
You're right.
In v1.5 (and earlier), it can be very slow to have
a loop where you "grow" a very long sequence by
concatenating smaller sequences onto the end of it each
time in a loop. However I recently optimized this case
so now it's very fast in my version. You'll see the
optimization in the next release.
Until then, do it the first way that you showed above.
Concatenating an atom onto a sequence in a loop
(or appending an atom onto a sequence) is
fast, because it has been specifically optimized.
Regards,
Rob Craig
Rapid Deployment Software
|
Not Categorized, Please Help
|
|