3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * bool isEven(int $number) * * use it to prove if a number is even or no * * @param int $number the number that you want to check * @return bool returns TRUE if the number is even, otherwise returns FALSE */ function isEven($number) { if(!($number % 2)) { return TRUE; } return FALSE; } print_r(isEven(2)); echo '<br>'; print_r(isEven(3)); echo '<br>'; print_r(isEven(50)); echo '<br>'; print_r(isEven(53));
Output for git.master, git.master_jit, rfc.property-hooks
1<br><br>1<br>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
38.9 ms | 401 KiB | 8 Q