3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $arr = array(1, 2, 3); if (!in_array(1, $arr)) { echo 1; } else if (in_array(1, $arr)) { echo 2; }
based on jGa89
Output for 4.3.0 - 7.3.0rc3
2