3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php print var_export(strcmp('a','b')); print var_export(strcmp('a','a')); print var_export(strcmp(array(),'b'));
Output for 5.3.0 - 5.6.28, 7.0.0 - 7.1.0
-10 Warning: strcmp() expects parameter 1 to be string, array given in /in/5c2ZR on line 5 NULL
Output for hhvm-3.10.0 - 3.13.2
-1101 Warning: strcmp() expects parameter 1 to be string, array given in /in/5c2ZR on line 5 NULL1
Output for 4.3.0 - 5.2.17
-10 Notice: Array to string conversion in /in/5c2ZR on line 5 -33