PHP 7.2.0 Release Candidate 2 Released

Voting

Please answer this simple SPAM challenge: min(three, two)?
(Example: nine)

The Note You're Voting On

petruzanauticoyahoo?com!ar
9 years ago
Regarding the ternary operator, I would rather say that the best option is to enclose all the expression in parantheses, to avoid errors and improve clarity:

<?php
  
print ( $a > 1 ? "many" : "just one" );
?>

PS: for php, C++, and any other language that has it.

<< Back to user notes page

To Top