3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function isOdd($var) { return($var & 1); } for($i = 0; $i < 10; $i++) { echo isOdd($i) == 1 ? 'odd' : 'even'; echo '<br />'; }
Output for 4.3.0 - 7.1.0
even<br />odd<br />even<br />odd<br />even<br />odd<br />even<br />odd<br />even<br />odd<br />