fork download
  1. <?php
  2. $a = (object)["a" => "b"];
  3. $b = (object)["a" => "c"];
  4. $y = $a <=> $b;
  5. echo $y;
  6. $v=[1,2,3] <=> [1,2,3];
  7. echo $v;
  8. $a= (object)["a" => "b"];
  9. $b = (object)["a" => "b"];
  10. echo $a <=> $b;
  11. echo ($y == -1)? 1:0;
  12.  
  13. //https://pt.stackoverflow.com/q/343530/101
Success #stdin #stdout 0s 82560KB
stdin
Standard input is empty
stdout
-1001object(stdClass)#3 (1) {
  ["a"]=>
  string(1) "b"
}