3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a = 23; $b = 2; $res = 0; $arr = null; for($i = $a; $res > 0; $i = $res) { $arr[] = $i % $b; // store remainder in array $res = $i / $b; } var_dump($arr);
Output for 4.3.0 - 7.1.0
NULL