3v4l.org

run code in 300+ PHP versions simultaneously
<?php $allValues = ['true', 'true', 'true']; echo array_all($allValues, fn($v) => $v === 'true') ? 'all true' : 'some false';
Output for 8.4.1 - 8.4.18, 8.5.0 - 8.5.3
all true
Output for 8.1.34, 8.2.0 - 8.2.30, 8.3.0 - 8.3.30
Fatal error: Uncaught Error: Call to undefined function array_all() in /in/oMkHN:5 Stack trace: #0 {main} thrown in /in/oMkHN on line 5
Process exited with code 255.

preferences:
59.54 ms | 849 KiB | 4 Q