3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $ids = array(); $items = array( 1, 5, 99, 129, 7, 2 ); foreach($items as $item) { array_push($ids, $item); } var_dump($ids);
Output for 4.3.0 - 7.1.0
array(6) { [0]=> int(1) [1]=> int(5) [2]=> int(99) [3]=> int(129) [4]=> int(7) [5]=> int(2) }