3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump(intdiv(3, 2)); var_dump(intdiv(-3, 2)); var_dump(intdiv(3, -2)); var_dump(intdiv(-3, -2)); var_dump(intdiv(PHP_INT_MAX, PHP_INT_MAX)); var_dump(intdiv(-PHP_INT_MAX - 1, -PHP_INT_MAX - 1)); var_dump(intdiv(-PHP_INT_MAX - 1, -1)); var_dump(intdiv(1, 0));
Output for git.master, git.master_jit, rfc.property-hooks
int(1) int(-1) int(-1) int(1) int(1) int(1) Fatal error: Uncaught ArithmeticError: Division of PHP_INT_MIN by -1 is not an integer in /in/NWPPT:8 Stack trace: #0 /in/NWPPT(8): intdiv(-9223372036854775808, -1) #1 {main} thrown in /in/NWPPT on line 8
Process exited with code 255.

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:
60.8 ms | 401 KiB | 8 Q