I thought I needed the brackets to get the particular line of code to work as expected but it turns out that I'm able to get the code to print 'plural' when $lines is greater than 1 and 'singular' when $lines equals 1.# without brackets print $lines > 1 ? 'plural' : 'singular'; # with brackets print ($lines > 1) ? 'plural' : 'singular';
In reply to What difference do the brackets make? by kiat
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |