3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $temp = ''; var_dump(count($temp)); foreach ($temp as $a){}
based on SfCC9
Output for 7.2.0
Warning: count(): Parameter must be an array or an object that implements Countable in /in/k5RAA on line 5 int(1) Warning: Invalid argument supplied for foreach() in /in/k5RAA on line 7
Output for 5.4.0 - 7.1.10
int(1) Warning: Invalid argument supplied for foreach() in /in/k5RAA on line 7