[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [FWP] COBOL as Perl



Brand wrote:
> 
> However, while this version looks more "perlish", it's not as
> efficient.  There's the temp copy of $left_key, the loop exit test
> each time through the loop, and an extra test when $left_key is less
> than $right_key.

Also note that if one stream is much longer than the other, some
performance gain can be had be detecting when one stream runs out,
and just processing the remainder of the other stream, without any
comparisons.

John Porter


==== Want to unsubscribe from Fun With Perl?
==== Well, if you insist... Send mail with body "unsubscribe" to
==== fwp-request@technofile.org