3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $model = array("id","car1","car2","car3"); $cars=array("Volvo","BMW","Toyota"); $arrlength=count($model); for($x=1;$x<$arrlength;$x++) { echo $cars[$x]; echo "\n"; } ?>
Output for 5.3.0 - 5.6.28, 7.0.0 - 7.1.0
BMW Toyota Notice: Undefined offset: 3 in /in/HQNlP on line 7
Output for hhvm-3.10.0 - 3.12.0
BMW Toyota Notice: Undefined index: 3 in /in/HQNlP on line 7
Output for 4.3.0 - 5.2.17
BMW Toyota Notice: Undefined offset: 3 in /in/HQNlP on line 7