3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $mykey = uniqid("\x00"); $var[$mykey] = TRUE; foreach($var as $key => $val) { if ($key === $mykey) { echo 'You got it right'; } else { echo 'You got it wrong'; } }
based on 0P9E8
Output for 7.1.0
You got it wrong
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.0.14
You got it right