"&&" and "and" have differing precedences. "and" is lower precedence than "&&". The same goes for "||" and "or"; "or" has lower precedence than "||". "and" actually has lower precedence than "||", as I will demonstrate.
code with "&&":
perl -e 'if(0&& 0||1){print"hello\n"}'
output:
hello
code with "and":
perl -e 'if(0and 0||1){print"hello\n"}'
(outputs nothing)
In reply to Re^4: Perl Parsing Based on Supplied Precedence
by protist
in thread Perl Parsing Based on Supplied Precedence
by protist
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |