3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $var[0] = array('Tokyo' => '東京', 'Osaka' => '大阪', 'Fukuoka' => '福岡'); $var[1] = array('Tokyo' => '東京?', 'Osaka' => '大阪?', 'Fukuoka' => '福岡?'); $rental_book_id = array(); foreach($var as $i){ echo $i->Osaka; }
Output for 5.0.0 - 5.6.28, 7.0.0 - 7.1.0
Notice: Trying to get property of non-object in /in/gLegQ on line 10 Notice: Trying to get property of non-object in /in/gLegQ on line 10
Output for hhvm-3.10.0 - 3.12.0
Notice: Cannot access property on non-object in /in/gLegQ on line 10 Notice: Cannot access property on non-object in /in/gLegQ on line 10
Output for 4.3.0 - 4.4.9