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.13
all true
Output for 8.2.0 - 8.2.29, 8.3.0 - 8.3.26
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:
49.41 ms | 407 KiB | 5 Q