in reply to Re: Print both elements in a compare
in thread Print both elements in a compare

Unfortunately I am unable to upgrade to Perl 5.10 at the moment so need to find a solution for Perl 5.8.8
I'm confused as to why the code produces the concatenation error as you've discovered.
The question is how do I get it to print both sides of the mismatch and I admit I hadn't catered for undef elements. Can you advise me on how to cater for both of those issues using the code posted ?

Replies are listed 'Best First'.
Re^3: Print both elements in a compare
by moritz (Cardinal) on Nov 01, 2010 at 22:19 UTC
    Can you advise me on how to cater for both of those issues using the code posted ?

    You can always use defined to check if an element is not undef, and do whatever you want with that information.

    Perl 6 - links to (nearly) everything that is Perl 6.