3v4l.org

run code in 300+ PHP versions simultaneously
<?php $numberFormatter = new NumberFormatter('bg', NumberFormatter::DECIMAL_COMPACT_SHORT); echo $numberFormatter->format(1200) . PHP_EOL; $numberFormatter = new NumberFormatter('EN', NumberFormatter::DECIMAL_COMPACT_SHORT); echo $numberFormatter->format(1200); $numberFormatter = new NumberFormatter('ES', NumberFormatter::DECIMAL_COMPACT_SHORT); echo $numberFormatter->format(1200);
Output for 8.5.1 - 8.5.3
Fatal error: Uncaught Error: Class "NumberFormatter" not found in /in/pKBRs:3 Stack trace: #0 {main} thrown in /in/pKBRs on line 3
Process exited with code 255.
Output for 8.5.0
1,2 хил. 1.2K1,2 mil
Output for 8.1.34, 8.2.28 - 8.2.30, 8.3.5 - 8.3.30, 8.4.5 - 8.4.18
Fatal error: Uncaught Error: Undefined constant NumberFormatter::DECIMAL_COMPACT_SHORT in /in/pKBRs:3 Stack trace: #0 {main} thrown in /in/pKBRs on line 3
Process exited with code 255.

preferences:
34.45 ms | 646 KiB | 4 Q