3v4l.org

run code in 300+ PHP versions simultaneously
<?php mt_srand(1234); echo mt_rand(100,1) . "\n";
Output for 5.3.4 - 5.3.29, 5.4.0 - 5.4.45, 5.5.24 - 5.5.35, 5.6.8 - 5.6.28, 7.0.0 - 7.0.20, 7.1.0 - 7.1.7
Warning: mt_rand(): max(1) is smaller than min(100) in /in/OfNE4 on line 3
Output for 5.2.1 - 5.2.17, 5.3.0 - 5.3.3
21
Output for 4.3.0 - 4.3.11, 4.4.0 - 4.4.9, 5.0.0 - 5.0.5, 5.1.0 - 5.1.6, 5.2.0
51

preferences:
108.46 ms | 402 KiB | 173 Q