3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace My\NS; const STDIN = 'f00'; echo STDIN, PHP_EOL; echo \STDIN, PHP_EOL; namespace My\Other; echo STDIN, PHP_EOL; echo \My\NS\STDIN, PHP_EOL;
Output for 8.3.5 - 8.3.28, 8.4.9 - 8.4.15, 8.5.0
f00 Resource id #1 Resource id #1 f00

preferences:
56.54 ms | 406 KiB | 5 Q