in reply to Re: Script to check for multiple files on FTP and print the one missing
in thread Script to check for multiple files on FTP and print the one missing

the if imposes scalar (i.e. boolean) context, so it's true if all arrays are not empty.

just try testing print scalar(@a && @b)

you could replace && with * and || with +.

I'm doing this if I explicitly want to avoid any short-circuit!

Cheers Rolf

( addicted to the Perl Programming Language)

Replies are listed 'Best First'.
Re^3: Script to check for multiple files on FTP and print the one missing
by zork42 (Monk) on Jul 01, 2013 at 03:55 UTC
    the if imposes scalar (i.e. boolean) context,
    I did not know that, thanks!

    Do you think perlop should make it clearer what "&&" means in list/array context?
    Or have I missed something?