3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $array = array('qwe','das'); foreach ( array( 'key_to_validate', 'another_one' ) as $key ) { echo trim($array[$key]); }
Output for 5.3.0 - 7.1.0
Notice: Undefined index: key_to_validate in /in/r9mDP on line 5 Notice: Undefined index: another_one in /in/r9mDP on line 5
Output for 4.3.0 - 5.2.17
Notice: Undefined index: key_to_validate in /in/r9mDP on line 5 Notice: Undefined index: another_one in /in/r9mDP on line 5