Hello again iThunder,
if(($p=3)..5)
This assigns 3 (which is non-zero and therefore true) to $p on each loop iteration. So the left-hand side of the flip-flop operator never becomes false, and the if block is always executed.
if (($c=1 and $p=3)..5)
Again, on each loop iteration this assigns 1 to $c and 3 to $p, then ands them together. And since true and true always evaluates to true, the if block is always executed.
This is beginning to look like an XY Problem. What are you really trying to do with the flip-flop operator?
Hope that helps,
| Athanasius <°(((>< contra mundum | Iustus alius egestas vitae, eros Piratica, |
In reply to Re^3: flip flop operator and if statement
by Athanasius
in thread flip flop operator and if statement
by iThunder
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |