3v4l.org

run code in 300+ PHP versions simultaneously
<?php $path = "/var/www/foo"; var_dump($pаth."/user/supplied/path"); // prints /user/supplied/path, and emits a notice // let's write a random number generator function crypto_rnd() { $rnd = mt_rand(0, 1e10); // 3v4l apparently doesn't have openssl_random_pseudo_bytes $today = date('c'); // extra entropy can't hurt! return hash("sha512", $rn.$today); // oops, that's actually r\u2060nd, which is undefined, i.e. NULL, i.e. pwned } var_dump(crypto_rnd() === crypto_rnd()); // uh oh...

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
7.4.00.0070.01015.00
7.3.120.0090.00914.66
7.3.110.0130.00315.11
7.3.100.0110.00614.80
7.3.90.0070.01315.07
7.3.80.0000.00914.96
7.3.70.0000.01414.89
7.3.60.0070.00714.95
7.3.50.0060.00814.70
7.3.40.0040.00814.70
7.3.30.0110.00015.00
7.3.20.0100.00316.78
7.3.10.0060.00616.72
7.3.00.0060.00916.73
7.2.250.0150.00015.19
7.2.240.0060.01014.89
7.2.230.0070.01015.26
7.2.220.0080.00315.02
7.2.210.0070.00714.95
7.2.200.0060.00314.98
7.2.190.0060.00914.79
7.2.180.0090.00614.66
7.2.170.0090.00415.21
7.2.130.0080.00617.10
7.2.120.0090.00617.00
7.2.110.0040.00717.00
7.2.100.0060.01017.09
7.2.90.0070.00717.12
7.2.80.0030.01216.99
7.2.70.0030.01217.02
7.2.60.0100.00317.04
7.2.50.0030.01417.00
7.2.40.0070.00717.03
7.2.30.0060.00617.03
7.2.20.0000.01416.77
7.2.10.0120.00316.96
7.2.00.0140.00016.96
7.1.330.0060.00615.98
7.1.320.0000.01515.94
7.1.310.0120.00015.69
7.1.300.0030.00615.54
7.1.290.0060.00615.68
7.1.280.0080.00515.88
7.1.270.0080.00615.71
7.1.260.0000.01215.73
7.1.250.0070.00315.99
7.1.70.0000.00817.30
7.1.60.0030.01019.46
7.1.50.0070.01616.91
7.1.00.0070.07022.57
7.0.200.0070.00716.68
7.0.140.0030.07321.97
7.0.100.0300.08020.01
7.0.90.0030.05319.86
7.0.80.0430.05319.96
7.0.70.0130.07319.98
7.0.60.0200.05319.92
7.0.50.0070.08320.25
7.0.40.0070.08720.15
7.0.30.0100.08320.00
7.0.20.0170.07020.18
7.0.10.0130.07720.14
7.0.00.0070.08319.98
5.6.280.0030.07321.07
5.6.250.0030.04720.64
5.6.240.0000.09020.75
5.6.230.0030.08320.54
5.6.220.0130.07720.57
5.6.210.0070.08720.49
5.6.200.0070.07021.04
5.6.190.0070.05721.14
5.6.180.0000.08721.11
5.6.170.0130.07721.03
5.6.160.0200.03720.94
5.6.150.0130.08021.04
5.6.140.0130.09021.10
5.6.130.0230.03321.13
5.6.120.0230.06721.11
5.6.110.0100.04320.95
5.6.100.0070.09021.04
5.6.90.0100.06021.06
5.6.80.0030.07320.39
5.6.70.0100.06320.42
5.6.60.0070.04320.46
5.6.50.0100.07720.35
5.6.40.0100.05720.42
5.6.30.0030.04020.45
5.6.20.0030.05720.52
5.6.10.0030.04320.40
5.6.00.0030.04720.33
5.5.380.0100.05020.33
5.5.370.0130.07020.40
5.5.360.0130.08020.35
5.5.350.0100.06020.46
5.5.340.0030.08020.83
5.5.330.0070.06320.80
5.5.320.0200.03720.88
5.5.310.0030.05320.64
5.5.300.0130.06720.76
5.5.290.0030.04320.85
5.5.280.0200.07720.82
5.5.270.0000.06020.82
5.5.260.0100.06320.88
5.5.250.0030.08720.68
5.5.240.0030.04020.32
5.5.230.0030.04720.19
5.5.220.0030.07720.26
5.5.210.0030.08720.30
5.5.200.0030.05319.98
5.5.190.0070.08020.23
5.5.180.0030.07320.08
5.5.160.0100.07020.11
5.5.150.0100.08020.21
5.5.140.0100.04019.98
5.5.130.0070.07320.23
5.5.120.0000.05020.08
5.5.110.0200.04720.24
5.5.100.0030.05320.02
5.5.90.0170.06720.06
5.5.80.0070.06720.04
5.5.70.0100.08020.08
5.5.60.0100.05020.06
5.5.50.0000.08320.00
5.5.40.0070.04320.00
5.5.30.0130.07720.05
5.5.20.0100.03319.96
5.5.10.0100.04720.11
5.5.00.0030.04719.95
5.4.450.0170.03719.47
5.4.440.0030.09319.45
5.4.430.0200.07019.37
5.4.420.0100.04319.35
5.4.410.0070.08019.14
5.4.400.0030.04019.04
5.4.390.0070.06019.11
5.4.380.0000.06318.89
5.4.370.0030.06019.12
5.4.360.0030.05018.90
5.4.350.0030.06019.18
5.4.340.0030.07718.95
5.4.320.0000.08019.05
5.4.310.0070.05019.13
5.4.300.0100.07019.16
5.4.290.0170.05019.03
5.4.280.0130.07019.04
5.4.270.0070.04719.12
5.4.260.0030.08319.20
5.4.250.0130.07018.94
5.4.240.0130.07319.04
5.4.230.0100.07719.04
5.4.220.0130.07318.89
5.4.210.0000.07719.17
5.4.200.0100.07319.02
5.4.190.0100.03019.02
5.4.180.0130.04719.22
5.4.170.0100.07318.86
5.4.160.0070.07319.11
5.4.150.0070.07319.02
5.4.140.0030.07016.45
5.4.130.0030.07716.33
5.4.120.0000.07016.19
5.4.110.0030.06016.51
5.4.100.0000.04016.39
5.4.90.0000.03716.39
5.4.80.0030.03316.34
5.4.70.0000.03716.25
5.4.60.0070.03716.46
5.4.50.0070.04016.46
5.4.40.0100.03016.50
5.4.30.0000.04016.50
5.4.20.0030.03716.36
5.4.10.0030.03716.29
5.4.00.0130.03015.90
5.3.290.0070.07714.80
5.3.280.0100.04014.66
5.3.270.0000.04014.71
5.3.260.0130.03314.71
5.3.250.0070.07014.69
5.3.240.0030.04314.58
5.3.230.0100.08014.60
5.3.220.0130.03314.54
5.3.210.0070.07714.62
5.3.200.0030.03714.58
5.3.190.0030.03714.70
5.3.180.0030.04014.70
5.3.170.0030.03714.62
5.3.160.0070.03314.68
5.3.150.0030.03714.67
5.3.140.0070.03314.57
5.3.130.0030.03714.68
5.3.120.0030.03714.55
5.3.110.0030.03714.66
5.3.100.0000.04014.18
5.3.90.0100.02314.00
5.3.80.0070.03014.02
5.3.70.0000.04014.16
5.3.60.0030.03713.93
5.3.50.0000.03313.89
5.3.40.0030.07314.05
5.3.30.0030.03013.97
5.3.20.0100.03013.72
5.3.10.0030.02713.64
5.3.00.0070.03013.57
5.2.170.0000.02711.17
5.2.160.0000.03711.13
5.2.150.0100.03011.05
5.2.140.0030.02711.05
5.2.130.0030.02711.20
5.2.120.0030.02311.18
5.2.110.0030.02311.18
5.2.100.0070.03711.11
5.2.90.0030.03011.23
5.2.80.0000.04011.16
5.2.70.0030.02711.20
5.2.60.0030.03011.14
5.2.50.0000.03010.93
5.2.40.0000.03011.01
5.2.30.0000.03011.02
5.2.20.0030.02710.86
5.2.10.0030.02310.87
5.2.00.0070.02310.82
5.1.60.0000.02710.71
5.1.50.0030.02310.71
5.1.40.0000.02310.71
5.1.30.0070.02010.71
5.1.20.0030.06010.71
5.1.10.0030.02310.71
5.1.00.0030.02310.71
5.0.50.0030.01710.71
5.0.40.0000.02010.71
5.0.30.0030.02710.71
5.0.20.0000.02010.71
5.0.10.0000.02310.71
5.0.00.0030.02710.71
4.4.90.0030.01310.71
4.4.80.0030.02010.71
4.4.70.0030.01310.71
4.4.60.0030.01710.71
4.4.50.0000.01310.71
4.4.40.0070.02010.71
4.4.30.0000.02010.71
4.4.20.0000.01310.71
4.4.10.0000.02710.71
4.4.00.0070.02010.71
4.3.110.0000.03010.71
4.3.100.0030.01310.71
4.3.90.0000.01710.71
4.3.80.0030.03010.71
4.3.70.0000.01710.71
4.3.60.0000.01310.71
4.3.50.0100.00710.71
4.3.40.0000.02310.71
4.3.30.0000.01710.71
4.3.20.0000.01710.71
4.3.10.0000.01710.71
4.3.00.0000.01310.71

preferences:
33.74 ms | 401 KiB | 5 Q