3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = true; $b = "ceva"; $c = 0; $d = false; if (($a == $b) && ($b == $c) && ($c == $d)) { // daca sunt egale intre ele echo "Cele 2 valori:"; var_dump($a); var_dump($d); echo 'sunt egale.'; } echo "\n\n\n"; if ((NULL == 0) && (NULL < -1)) { echo "0 e mai mic decat -1"; } echo "\n\n\n"; $string = "123abc"; $a = 123; $b = "123"; if (($a == $string) && ($b != $string)) { echo "$a == $string is true \n$b != $string is true"; } echo "\n\n\n"; $s1 = " 6"; $s2 = "6"; if ($s1 == $s2) { echo "'$s1' == '$s2'"; } echo "\n\n\n"; $a = md5('240610708'); $b = md5('QNKCDZO'); if ($a == $b) { echo "$a\nsi\n$b\nsunt egale"; }
based on 5nPSL
Output for 4.3.0 - 7.2.0
Cele 2 valori:bool(true) bool(false) sunt egale. 0 e mai mic decat -1 123 == 123abc is true 123 != 123abc is true ' 6' == '6' 0e462097431906509019562988736854 si 0e830400451993494058024219903391 sunt egale