Hello All, I want to know which PHP version quipped to spaceship operator between php5 and php7. As I am working on php5, PHP5 does not have a spaceship operator. A lot of operators have to be used for comparisons. I have checked on google and according to this source, PHP7 is quipped with a new operator popularly referred to as spaceship operator which has a notation <=> Function can automatically return to null when the value is not accessible. Can anyone tell me, Is PHP7 is better than phph5 in terms of spaceship operator?
Spaceship Operator in PHP 5 and 7
ankitdixit Is PHP7 is better than phph5 in terms of spaceship operator?
Yes, because PHP 5 doesn't have that operator.
https://www.php.net/manual/en/language.operators.comparison.php
7 months later
NogDog locked the discussion.