3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = ''; $testone = 0; $testtwo = 0.0; $testthree = array(); $testfour = fopen("http://ya.ru", "r"); if(empty($foo)) echo "Foo is empty - ". gettype($foo); // Foo is empty - string if(empty($bar)) echo 'Bar is empty too - '. gettype($bar); // Notice: Undefined variable: bar in /in/kCIj8 on line 7 Bar is empty too - NULL if(empty($testone)) echo 'Testone is empty - '.gettype($testone); if(empty($testtwo)) echo 'Testtwo is empty - '.gettype($testtwo); if(empty($testthree)) echo 'Testthree is empty - '.gettype($testthree); if(empty($testfour)) echo 'Testtwo is empty'.gettype($testthree); else echo "Testfour's not empty -".var_dump($testfour); ?>

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)
8.3.60.0140.00318.68
8.3.50.0110.00718.17
8.3.40.0030.01219.00
8.3.30.0040.01118.66
8.3.20.0030.00619.39
8.3.10.0030.00522.23
8.3.00.0120.00321.15
8.2.180.0110.00716.88
8.2.170.0150.00622.96
8.2.160.0070.01119.20
8.2.150.0040.00424.18
8.2.140.0070.00724.66
8.2.130.0110.00420.78
8.2.120.0080.00026.35
8.2.110.0090.00020.82
8.2.100.0000.01118.03
8.2.90.0080.00018.15
8.2.80.0060.00318.05
8.2.70.0000.00817.75
8.2.60.0040.00418.05
8.2.50.0090.00018.10
8.2.40.0050.00320.66
8.2.30.0070.00019.38
8.2.20.0030.00618.04
8.2.10.0080.00018.28
8.2.00.0000.00718.45
8.1.280.0150.00025.92
8.1.270.0000.00724.08
8.1.260.0040.00428.09
8.1.250.0040.00428.09
8.1.240.0060.00324.11
8.1.230.0080.00324.13
8.1.220.0030.00517.91
8.1.210.0040.00419.22
8.1.200.0030.00617.25
8.1.190.0000.00817.35
8.1.180.0080.00018.10
8.1.170.0040.00418.76
8.1.160.0050.00219.15
8.1.150.0030.00519.00
8.1.140.0060.00319.85
8.1.130.0030.00317.80
8.1.120.0040.00417.59
8.1.110.0060.00317.60
8.1.100.0070.00017.59
8.1.90.0040.00417.53
8.1.80.0000.00717.50
8.1.70.0040.00417.59
8.1.60.0040.00417.72
8.1.50.0060.00317.68
8.1.40.0000.00817.64
8.1.30.0000.00917.72
8.1.20.0050.00517.93
8.1.10.0070.00017.71
8.1.00.0000.00817.61
8.0.300.0040.00420.23
8.0.290.0040.00417.13
8.0.280.0000.00818.74
8.0.270.0000.00717.61
8.0.260.0030.00317.51
8.0.250.0000.00717.20
8.0.240.0000.00817.15
8.0.230.0030.00617.25
8.0.220.0050.00217.18
8.0.210.0050.00317.17
8.0.200.0070.00017.33
8.0.190.0030.00617.32
8.0.180.0040.00417.16
8.0.170.0040.00417.18
8.0.160.0040.00417.14
8.0.150.0000.00817.11
8.0.140.0050.00217.11
8.0.130.0030.00313.82
8.0.120.0030.00517.19
8.0.110.0080.00017.28
8.0.100.0040.00417.32
8.0.90.0000.00817.28
8.0.80.0100.00717.23
8.0.70.0000.01117.16
8.0.60.0080.00017.17
8.0.50.0040.00417.14
8.0.30.0130.00817.32
8.0.20.0130.01117.43
8.0.10.0040.00417.29
8.0.00.0140.00417.10
7.4.330.0000.00515.21
7.4.320.0050.00516.68
7.4.300.0000.00716.73
7.4.290.0090.00316.66
7.4.280.0000.00716.72
7.4.270.0060.00016.78
7.4.260.0070.00016.70
7.4.250.0040.00416.81
7.4.240.0040.00416.90
7.4.230.0040.00416.74
7.4.220.0180.00316.77
7.4.210.0060.00816.92
7.4.200.0040.00416.92
7.4.160.0060.01016.83
7.4.150.0120.01217.40
7.4.140.0120.01117.86
7.4.130.0110.01316.80
7.4.120.0110.01316.87
7.4.110.0090.00916.87
7.4.100.0060.01316.80
7.4.90.0100.01316.76
7.4.80.0060.01219.39
7.4.70.0030.01516.85
7.4.60.0030.01316.83
7.4.50.0070.01116.85
7.4.40.0120.00916.82
7.4.30.0100.00716.77
7.4.00.0090.00615.32
7.3.330.0060.00013.42
7.3.320.0000.00513.63
7.3.310.0000.00816.76
7.3.300.0070.00016.64
7.3.290.0070.00716.59
7.3.280.0120.00916.64
7.3.270.0150.00317.40
7.3.260.0140.01816.71
7.3.250.0130.00716.64
7.3.240.0110.01016.61
7.3.230.0110.00716.80
7.3.210.0110.01016.77
7.3.200.0030.01316.66
7.3.190.0070.01116.71
7.3.180.0060.01216.72
7.3.170.0120.00916.76
7.3.160.0160.00316.53
7.2.330.0090.00916.81
7.2.320.0060.01316.87
7.2.310.0150.01316.69
7.2.300.0030.01416.76
7.2.290.0060.01216.78
7.2.60.0050.01016.66
7.2.00.0130.00719.63
7.1.200.0070.00716.11
7.1.100.0240.00018.05
7.1.70.0030.00617.45
7.1.60.0130.01319.47
7.1.50.0200.01017.08
7.1.00.0030.07322.76
7.0.200.0300.01214.92
7.0.70.1630.04020.43
7.0.60.1570.05720.39
7.0.50.1270.06720.74
7.0.40.1130.06020.82
7.0.30.1230.07020.73
7.0.20.1100.06320.78
7.0.10.1100.06720.76
7.0.00.1230.06020.66
5.6.280.0030.07321.34
5.6.220.1530.07721.04
5.6.210.1300.06721.05
5.6.200.1270.05721.45
5.6.190.1100.06021.46
5.6.180.1070.05721.58
5.6.170.0970.06321.46
5.6.160.0930.05721.59
5.6.150.1200.07321.46
5.6.140.1200.06021.52
5.6.130.1230.06321.30
5.6.120.0200.06721.30
5.6.110.0600.06021.43
5.6.100.1330.05721.41
5.6.90.1170.06321.48
5.6.80.1300.04720.67
5.6.70.1200.06020.79
5.6.60.1100.06720.65
5.6.50.1000.06020.96
5.6.40.1230.05320.84
5.6.30.1170.05720.84
5.6.20.1300.05320.82
5.6.10.1400.07720.85
5.6.00.1300.04720.82
5.5.360.1370.07020.70
5.5.350.1330.06020.80
5.5.340.1400.08721.24
5.5.330.1030.05021.22
5.5.320.1030.06021.37
5.5.310.1130.08721.25
5.5.300.1070.05721.30
5.5.290.1130.05321.17
5.5.280.0170.05721.02
5.5.270.1030.05721.33
5.5.260.1030.06321.33
5.5.250.1000.06021.03
5.5.240.0970.06020.67
5.5.230.1200.05720.75
5.5.220.1100.05720.73
5.5.210.1030.06320.62
5.5.200.1200.05720.69
5.5.190.1200.05720.55
5.5.180.1270.06320.70
5.5.160.0930.06720.70
5.5.150.1030.05020.58
5.5.140.1030.07020.71
5.5.130.1100.06720.70
5.5.120.1400.06020.74
5.5.110.1000.06320.61
5.5.100.1200.07020.61
5.5.90.1200.06320.40
5.5.80.1200.05320.38
5.5.70.1030.07020.34
5.5.60.1170.06020.56
5.5.50.1300.07020.47
5.5.40.1400.05320.57
5.5.30.1200.05720.56
5.5.20.0930.06720.41
5.5.10.1230.06020.45
5.5.00.1200.06320.58

preferences:
52.08 ms | 401 KiB | 5 Q