3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function sendemail($id_list,$userid){ foreach($id_list as $id) { printf("$id\n"); // Will run twice, once outputting id1, then id2 } } $idl = Array("id1", "id2"); $uid = "userID"; sendemail($idl, $uid);
Output for 4.3.0 - 7.2.0
id1 id2