3v4l.org

run code in 300+ PHP versions simultaneously
<?php class BlogCommentRepository { public function find($something) { echo "called!"; return array('key' => 'value'); } } $blogCommentRepository = new BlogCommentRepository(); $blogCommentIds = array(1,2,3,4); foreach ($blogCommentRepository->find(explode(",", $blogCommentIds)) as $blogCommentId) { // }

preferences:
35.67 ms | 402 KiB | 5 Q