3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $canadians = array( 'Bieber' => TRUE, 'Neil Young' => TRUE, 'Deadmau5' => TRUE, 'Barack Obama' => FALSE, 'John Candy' => TRUE, ); foreach ($canadians as $name => $real) { if($real) { print $name . ' is Canadian '; } elseif(!$real) { print $name . ', not Canadian '; } }
Output for 4.3.0 - 7.1.0
Bieber is Canadian Neil Young is Canadian Deadmau5 is Canadian Barack Obama, not Canadian John Candy is Canadian