in reply to Kindly let me know what exactly && does in Perl
The first decisive value is returned by || and &&.
If the whole && expression is true can only be known by the last value (which must also be true and is returned), otherwise the first false value is returned.
And vice versa for || - just swap true and false.
HTH :)
Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Updated wording, see reply for details.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Kindly let me know what exactly && does in Perl
by Anonymous Monk on Sep 07, 2014 at 17:06 UTC | |
by LanX (Saint) on Sep 07, 2014 at 17:27 UTC |