3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xmlstr = file_get_contents('http://designdelicatessen.com/_source/modules/shop_priceindex/export.php?index=test&iso=uk&site=1'); $feed = new SimpleXMLElement($xmlstr); function findPrice($feed, $id){ foreach($feed->Products->Product as $product){ if($product->Number == $id){ return $product->Price; } } return null; } echo findPrice($feed, 'swv8813'); echo "\n"; echo findPrice($feed, 'swv8814');

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.0120.00318.93
8.3.50.0140.00722.12
8.3.40.0110.00419.39
8.3.30.0110.00319.27
8.3.20.0080.00020.41
8.3.10.0080.00020.78
8.3.00.0040.00419.25
8.2.180.0110.00717.00
8.2.170.0070.00722.96
8.2.160.0140.00320.65
8.2.150.0030.00524.18
8.2.140.0000.00824.66
8.2.130.0040.00419.48
8.2.120.0050.00326.35
8.2.110.0080.00421.29
8.2.100.0040.00818.03
8.2.90.0040.00419.36
8.2.80.0000.00818.00
8.2.70.0080.00017.75
8.2.60.0030.00518.15
8.2.50.0030.00518.09
8.2.40.0030.00622.57
8.2.30.0000.00719.58
8.2.20.0050.00317.87
8.2.10.0000.00818.11
8.2.00.0050.00318.18
8.1.280.0070.01425.92
8.1.270.0030.00524.11
8.1.260.0060.00328.09
8.1.250.0080.00028.09
8.1.240.0060.00324.04
8.1.230.0040.00719.05
8.1.220.0000.00817.88
8.1.210.0080.00018.77
8.1.200.0040.00717.47
8.1.190.0030.00717.47
8.1.180.0000.00818.10
8.1.170.0090.00018.76
8.1.160.0040.00421.14
8.1.150.0080.00019.02
8.1.140.0030.00519.71
8.1.130.0070.00017.83
8.1.120.0020.00517.51
8.1.110.0050.00217.64
8.1.100.0000.00717.41
8.1.90.0000.00717.52
8.1.80.0000.00817.49
8.1.70.0000.00717.59
8.1.60.0050.00517.62
8.1.50.0040.00417.55
8.1.40.0000.00817.66
8.1.30.0000.00817.73
8.1.20.0040.00417.83
8.1.10.0040.00417.75
8.1.00.0040.00417.67
8.0.300.0040.00418.77
8.0.290.0070.00017.00
8.0.280.0000.00718.52
8.0.270.0000.00717.39
8.0.260.0030.00517.40
8.0.250.0030.00317.05
8.0.240.0080.00017.06
8.0.230.0030.00317.00
8.0.220.0040.00417.08
8.0.210.0000.00717.06
8.0.200.0030.00317.18
8.0.190.0000.00717.16
8.0.180.0030.00717.18
8.0.170.0080.00017.01
8.0.160.0040.00317.15
8.0.150.0000.00717.19
8.0.140.0060.00317.02
8.0.130.0000.00513.76
8.0.120.0050.00317.23
8.0.110.0040.00417.07
8.0.100.0040.00417.12
8.0.90.0080.00017.19
8.0.80.0100.00717.23
8.0.70.0040.00417.09
8.0.60.0040.00417.29
8.0.50.0040.00417.04
8.0.30.0120.00717.42
8.0.20.0140.00517.40
8.0.10.0040.00417.23
8.0.00.0170.00617.06
7.4.330.0050.00015.25
7.4.320.0000.00616.57
7.4.300.0030.00316.71
7.4.290.0000.00716.54
7.4.280.0040.00416.63
7.4.270.0030.00516.73
7.4.260.0030.00316.82
7.4.250.0070.00216.79
7.4.240.0050.00216.77
7.4.230.0000.00716.57
7.4.220.0090.01016.79
7.4.210.0030.01216.92
7.4.200.0070.00016.83
7.4.160.0100.00616.79
7.4.150.0080.01117.40
7.4.140.0110.00817.86
7.4.130.0090.01416.80
7.4.120.0080.01116.82
7.4.110.0100.01316.61
7.4.100.0100.01016.66
7.4.90.0120.00616.68
7.4.80.0100.01019.39
7.4.70.0100.00716.71
7.4.60.0080.01116.89
7.4.50.0130.00316.80
7.4.40.0060.01116.74
7.4.30.0070.01016.81
7.4.10.0090.00915.31
7.4.00.0090.00915.14
7.3.330.0050.00513.52
7.3.320.0000.00513.36
7.3.310.0000.00716.47
7.3.300.0000.00816.55
7.3.290.0110.00516.63
7.3.280.0060.01216.65
7.3.270.0100.00717.40
7.3.260.0110.00716.73
7.3.250.0110.00816.65
7.3.240.0140.00616.63
7.3.230.0070.01016.66
7.3.210.0090.00916.61
7.3.200.0070.01116.58
7.3.190.0090.01016.52
7.3.180.0160.00616.58
7.3.170.0060.01316.56
7.3.160.0150.00316.51
7.3.130.0090.00914.90
7.3.120.0130.00615.17
7.3.110.0090.00915.04
7.3.100.0060.00914.94
7.3.90.0000.01415.08
7.3.80.0000.01114.92
7.3.70.0040.00815.09
7.3.60.0000.01814.85
7.3.50.0080.00415.13
7.3.40.0110.00415.00
7.3.30.0060.00915.11
7.3.20.0130.00416.96
7.3.10.0080.00316.80
7.3.00.0030.00716.71
7.2.330.0190.00016.61
7.2.320.0160.00316.89
7.2.310.0060.01316.82
7.2.300.0090.01616.80
7.2.290.0130.00316.89
7.2.260.0100.01015.50
7.2.250.0120.00915.45
7.2.240.0070.01015.46
7.2.230.0120.00615.16
7.2.220.0070.01415.20
7.2.210.0000.01615.23
7.2.200.0150.00415.17
7.2.190.0040.00815.23
7.2.180.0000.01415.36
7.2.170.0100.00315.26
7.2.160.0040.01315.12
7.2.150.0060.00917.18
7.2.140.0140.00317.02
7.2.130.0040.01117.07
7.2.120.0070.00717.18
7.2.110.0070.00716.96
7.2.100.0070.01016.83
7.2.90.0050.00517.20
7.2.80.0130.00016.88
7.2.70.0000.00916.81
7.2.60.0020.01216.90
7.2.50.0040.01417.23
7.2.40.0070.00717.09
7.2.30.0000.01617.17
7.2.20.0110.00417.24
7.2.10.0090.00617.04
7.2.00.0040.01018.24
7.1.330.0080.00815.89
7.1.320.0000.02016.08
7.1.310.0100.00715.95
7.1.300.0000.01116.08
7.1.290.0040.00816.16
7.1.280.0040.01215.99
7.1.270.0080.00315.87
7.1.260.0040.00816.02
7.1.250.0070.00716.00
7.1.240.0000.00915.71
7.1.230.0030.01215.79
7.1.220.0030.01015.95
7.1.210.0060.00316.02
7.1.200.0040.00716.07
7.1.190.0040.00716.07
7.1.180.0040.00716.05
7.1.170.0070.01016.02
7.1.160.0060.00816.10
7.1.150.0110.00416.01
7.1.140.0000.01315.92
7.1.130.0060.00916.07
7.1.120.0060.00616.10
7.1.110.0000.01316.18
7.1.100.0080.00617.15
7.1.90.0070.00715.70
7.1.80.0030.01015.76
7.1.70.0060.00416.75
7.1.60.0100.00717.64
7.1.50.0050.01116.81
7.1.40.0080.00415.86
7.1.30.0060.00616.01
7.1.20.0000.01415.83
7.1.10.0110.00416.05
7.1.00.0060.03619.40
7.0.330.0130.00015.51
7.0.320.0040.00815.57
7.0.310.0090.00615.54
7.0.300.0070.00715.61
7.0.290.0000.01115.60
7.0.280.0000.01515.51
7.0.270.0100.00715.46
7.0.260.0060.00615.75
7.0.250.0030.00915.49
7.0.240.0120.00315.69
7.0.230.0130.00315.69
7.0.220.0060.00615.50
7.0.210.0000.01315.57
7.0.200.0170.00515.59
7.0.190.0030.00615.70
7.0.180.0110.00315.84
7.0.170.0060.00515.47
7.0.160.0070.00715.36
7.0.150.0030.01215.62
7.0.140.0130.00015.68
7.0.130.0000.01415.36
7.0.120.0080.00415.39
7.0.110.0000.01415.88
7.0.100.0040.00815.58
7.0.90.0040.00815.77
7.0.80.0110.00415.79
7.0.70.0060.00615.63
7.0.60.0070.03919.02
7.0.50.0020.02616.96
7.0.40.0090.04517.07
7.0.30.0220.03817.12
7.0.20.0120.02717.04
7.0.10.0040.04217.17
7.0.00.0090.02717.04
5.6.400.0060.00614.61
5.6.390.0040.01214.64
5.6.380.0160.00014.65
5.6.370.0110.00314.48
5.6.360.0030.01014.71
5.6.350.0000.01214.33
5.6.340.0060.00914.84
5.6.330.0040.01114.84
5.6.320.0090.00614.73
5.6.310.0100.00714.53
5.6.300.0070.01114.62
5.6.290.0100.00314.50
5.6.280.0100.03518.00
5.6.270.0090.00614.30
5.6.260.0030.00614.23
5.6.250.0110.00314.61
5.6.240.0030.01014.54
5.6.230.0090.00314.69
5.6.220.0090.00614.48
5.6.210.0080.04417.63
5.6.200.0030.03816.60
5.6.190.0050.04517.87
5.6.180.0180.04117.84
5.6.170.0130.02917.63
5.6.160.0050.02817.66
5.6.150.0070.04716.50
5.6.140.0100.04016.51
5.6.130.0020.02916.59
5.6.120.0060.04118.08
5.6.110.0080.04817.91
5.6.100.0080.04517.90
5.6.90.0070.04617.88
5.6.80.0110.04017.54
5.6.70.0030.00814.43
5.6.60.0090.00614.49
5.6.50.0070.01014.67
5.6.40.0060.00914.20
5.6.30.0090.00614.56
5.6.20.0050.00514.45
5.6.10.0090.00614.43
5.6.00.0090.00914.39
5.5.380.0040.01114.39
5.5.370.0060.00614.32
5.5.360.0000.01014.36
5.5.350.2000.02417.52
5.5.340.0020.03516.24
5.5.330.0050.03017.63
5.5.320.0170.04117.50
5.5.310.0200.04117.64
5.5.300.0100.02716.40
5.5.290.0080.04216.43
5.5.280.0090.03717.84
5.5.270.0050.04717.76
5.5.260.0170.03017.84
5.5.250.0080.04817.74
5.5.240.0160.03717.38
5.5.230.0070.01014.55
5.5.220.0060.00814.27
5.5.210.0000.01314.32
5.5.200.0080.00414.06
5.5.190.0070.00714.28
5.5.180.0000.01014.36
5.5.170.0090.00314.52
5.5.160.0110.00314.32
5.5.150.0120.00414.42
5.5.140.0070.00714.37
5.5.130.0070.01014.37
5.5.120.0100.00614.35
5.5.110.0060.00314.32
5.5.100.0160.00014.36
5.5.90.0030.01314.61
5.5.80.0070.00714.23
5.5.70.0070.00714.02
5.5.60.0060.00314.28
5.5.50.0070.00714.54
5.5.40.0090.00413.94
5.5.30.0070.00314.31
5.5.20.0000.01114.25
5.5.10.0000.01214.21
5.5.00.0030.01014.61

preferences:
72.18 ms | 401 KiB | 5 Q