3v4l.org

run code in 500+ PHP versions simultaneously
<?php declare(strict_types=1); echo intdiv(round(13.5), 10);
Output for 8.1.0 - 8.1.34, 8.2.0 - 8.2.30, 8.3.0 - 8.3.30, 8.4.1 - 8.4.18, 8.5.0 - 8.5.3
Fatal error: Uncaught TypeError: intdiv(): Argument #1 ($num1) must be of type int, float given in /in/2A1el:3 Stack trace: #0 /in/2A1el(3): intdiv(14.0, 10) #1 {main} thrown in /in/2A1el on line 3
Process exited with code 255.
Output for 8.0.1 - 8.0.30
Fatal error: Uncaught TypeError: intdiv(): Argument #1 ($num1) must be of type int, float given in /in/2A1el:3 Stack trace: #0 /in/2A1el(3): intdiv(14, 10) #1 {main} thrown in /in/2A1el on line 3
Process exited with code 255.

preferences:
73.45 ms | 1135 KiB | 4 Q