But that will always do two tests. If the test is expensive, or done a lot of times, it's less efficient.$x = 8 if $x == 7; $x = 0 if not $x == 7;
But what is worse is that it's wrong. The original code ends with x being 8 if it was originally 7. Your code ends with $x being 0, all the time.
Abigail
In reply to Re: No braces
by Abigail-II
in thread No braces
by jacques
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |