3v4l.org

run code in 300+ PHP versions simultaneously
<?php function r(){ return rand(1,10); } if(empty(r())){ echo 'web'; }else{ echo 'lol'; }

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.0090.00615.04
7.3.120.0060.00914.92
7.3.110.0100.01014.37
7.3.100.0060.00914.75
7.3.90.0030.00614.41
7.3.80.0030.00714.98
7.3.70.0070.01014.54
7.3.60.0120.00314.84
7.3.50.0040.00414.79
7.3.40.0090.00614.76
7.3.30.0100.01014.86
7.3.20.0030.00616.59
7.3.10.0000.01016.54
7.3.00.0030.01016.73
7.2.250.0090.01214.77
7.2.240.0070.01114.80
7.2.230.0100.00714.92
7.2.220.0030.00615.15
7.2.210.0060.00914.98
7.2.200.0080.00414.83
7.2.190.0110.00414.88
7.2.180.0030.01214.55
7.2.170.0080.00414.88
7.1.330.0060.00615.59
7.1.320.0000.01015.88
7.1.310.0060.01015.61
7.1.300.0090.00015.51
7.1.290.0070.00415.52
7.1.280.0100.01015.70
7.1.270.0070.00315.48
7.1.260.0000.01115.38
7.1.70.0040.00816.97
7.1.60.0070.01819.59
7.1.50.0150.01134.59
7.1.00.0070.07322.54
7.0.200.0040.00416.48
7.0.60.0170.07719.85
7.0.50.0100.08017.72
7.0.40.0100.04720.09
7.0.30.0570.07020.26
7.0.20.0270.05320.16
7.0.10.0270.07720.16
7.0.00.0130.08320.02
5.6.280.0000.07320.89
5.6.210.0130.07320.77
5.6.200.0070.07318.15
5.6.190.0070.05320.50
5.6.180.3970.03720.42
5.6.170.0230.04720.62
5.6.160.0070.04320.55
5.6.150.0100.04318.16
5.6.140.0030.04018.14
5.6.130.0130.07018.14
5.6.120.0100.08021.04
5.6.110.0070.08721.02
5.6.100.0170.06021.01
5.6.90.0130.07720.88
5.6.80.0100.07320.54
5.6.70.0270.07720.40
5.5.350.0200.08020.49
5.5.340.0000.09017.95
5.5.330.0030.06020.43
5.5.320.0370.04020.25
5.5.310.0200.08320.20
5.5.300.0000.06017.91
5.5.290.0100.07017.98
5.5.280.0070.05720.89
5.5.270.0130.07720.79
5.5.260.0030.08720.77
5.5.250.0130.05320.70
5.5.240.0370.06020.23
5.4.450.1970.05719.35
5.4.440.1870.05019.22
5.4.430.1670.03719.43
5.4.420.1700.03319.51
5.4.410.1770.03319.06
5.4.400.1930.03719.14
5.4.390.1600.04019.31
5.4.380.1670.04019.00
5.4.370.1630.03718.87
5.4.360.1700.03319.22
5.4.350.1670.03319.22
5.4.340.1630.03719.09
5.4.320.1730.03319.15
5.4.310.1600.04019.16
5.4.300.1700.03319.08
5.4.290.1900.04019.08
5.4.280.1970.04318.87
5.4.270.1900.03318.95
5.4.260.1830.04719.16
5.4.250.2000.04019.30
5.4.240.1770.04019.08
5.4.230.1730.05319.12
5.4.220.1600.03719.06
5.4.210.1770.05019.16
5.4.200.1900.04019.20
5.4.190.1630.03319.23
5.4.180.1770.04319.14
5.4.170.1870.04718.86
5.4.160.1830.04719.11
5.4.150.1530.04318.93
5.4.140.1830.04316.42
5.4.130.1770.03716.50
5.4.120.1400.04316.51
5.4.110.1600.03716.25
5.4.100.1600.03316.58
5.4.90.1930.03716.56
5.4.80.1600.03716.55
5.4.70.1570.03716.50
5.4.60.1600.03716.52
5.4.50.1800.04016.18
5.4.40.1800.03716.58
5.4.30.1830.03716.43
5.4.20.1930.04016.53
5.4.10.1870.04016.16
5.4.00.1930.04015.78
5.3.290.1900.03714.71
5.3.280.1630.03314.50
5.3.270.1870.04314.51
5.3.260.1970.04014.61
5.3.250.1800.04714.62
5.3.240.1870.04314.52
5.3.230.1870.04014.65
5.3.220.1930.04014.55
5.3.210.1870.04014.62
5.3.200.1630.03314.81
5.3.190.1800.04014.47
5.3.180.1870.04314.48
5.3.170.1670.04014.55
5.3.160.1830.04314.47
5.3.150.1830.04714.58
5.3.140.1670.03314.54
5.3.130.1670.03714.52
5.3.120.2000.04714.47
5.3.110.1870.04714.63
5.3.100.1770.04014.26
5.3.90.1730.03014.13
5.3.80.2030.03713.93
5.3.70.1970.04313.92
5.3.60.1930.04313.90
5.3.50.1700.04014.16
5.3.40.1670.03713.85
5.3.30.1570.03313.95
5.3.20.2170.03313.60
5.3.10.1670.03713.57
5.3.00.1630.04013.65
5.2.170.1430.02711.22
5.2.160.1600.03311.22
5.2.150.1600.03711.20
5.2.140.1670.03011.20
5.2.130.1430.02711.20
5.2.120.1330.03311.20
5.2.110.1500.03011.20
5.2.100.1630.03311.32
5.2.90.1400.02711.20
5.2.80.1470.03711.20
5.2.70.1670.02711.20
5.2.60.1500.02711.20
5.2.50.1900.02711.20
5.2.40.1070.02711.20
5.2.30.1030.02711.20
5.2.20.1300.03311.20
5.2.10.1230.04011.20
5.2.00.1100.02711.20
5.1.60.1430.02011.20
5.1.50.1270.03711.20
5.1.40.1330.03011.20
5.1.30.1200.02311.20
5.1.20.1230.04011.20
5.1.10.1270.03011.20
5.1.00.1200.03711.20
5.0.50.0670.02011.20
5.0.40.0730.02711.20
5.0.30.0570.04011.20
5.0.20.0730.03011.20
5.0.10.0700.03311.20
5.0.00.0600.03311.20
4.4.90.0600.02011.20
4.4.80.0530.01311.20
4.4.70.0670.01311.20
4.4.60.0700.02711.20
4.4.50.0630.02011.20
4.4.40.0530.02711.20
4.4.30.0630.02011.20
4.4.20.0600.02711.20
4.4.10.0570.01311.20
4.4.00.0700.03711.20
4.3.110.0730.02011.20
4.3.100.0670.02711.20
4.3.90.0600.01711.20
4.3.80.0630.04011.20
4.3.70.0530.01711.20
4.3.60.0600.02311.20
4.3.50.0530.01711.20
4.3.40.0600.02711.20
4.3.30.0300.02011.20
4.3.20.0230.01711.20
4.3.10.0230.01711.20
4.3.00.0370.02711.20

preferences:
16.3 ms | 403 KiB | 5 Q