3v4l.org

run code in 300+ PHP versions simultaneously
<?php $html = <<<'EOD' <div class="a-fixed-left-grid"><div class="a-fixed-left-grid-inner" style="padding-left:200px"> <div class="a-fixed-left-grid-col a-col-left" style="width:200px;margin-left:-200px;float:left;"> <div class="a-section a-spacing-small a-text-center"> <span class="a-size-base a-color-secondary"> 4.5 étoiles sur 5 </span> </div> <table id="histogramTable" class="a-normal a-align-middle a-spacing-base"> <tr class="a-histogram-row"> <td class="a-nowrap"> <span class="a-size-small"> <a class="a-link-normal" title="76% des commentaires ont reçu 5 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_5?ie=UTF8&filterByStar=five_star&showViewpoints=0">5 étoiles</a> </span> <span class="a-letter-space"></span> </td> <td class="a-span10"> <a class="a-link-normal" title="76% des commentaires ont reçu 5 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_5?ie=UTF8&filterByStar=five_star&showViewpoints=0"><div class="a-meter" aria-label="76%"><div class="a-meter-bar" style="width: 76%;"></div></div></a> </td> <td class="a-nowrap"> <span class="a-letter-space"></span><span class="a-size-small">76%</span> </td> </tr> <tr class="a-histogram-row"> <td class="a-nowrap"> <span class="a-size-small"> <a class="a-link-normal" title="12% des commentaires ont reçu 4 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_4?ie=UTF8&filterByStar=four_star&showViewpoints=0">4 étoiles</a> </span> <span class="a-letter-space"></span> </td> <td class="a-span10"> <a class="a-link-normal" title="12% des commentaires ont reçu 4 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_4?ie=UTF8&filterByStar=four_star&showViewpoints=0"><div class="a-meter" aria-label="12%"><div class="a-meter-bar" style="width: 12%;"></div></div></a> </td> <td class="a-nowrap"> <span class="a-letter-space"></span><span class="a-size-small">12%</span> </td> </tr> <tr class="a-histogram-row"> <td class="a-nowrap"> <span class="a-size-small">3 étoiles</span> <span class="a-letter-space"></span> </td> <td class="a-span10"> <div class="a-meter" aria-label="0%"><div class="a-meter-bar" style="width: 0%;"></div></div> </td> <td class="a-nowrap"> <span class="a-letter-space"></span><span class="a-size-small">0%</span> </td> </tr> <tr class="a-histogram-row"> <td class="a-nowrap"> <span class="a-size-small"> <a class="a-link-normal" title="12% des commentaires ont reçu 2 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_2?ie=UTF8&filterByStar=two_star&showViewpoints=0">2 étoiles</a> </span> <span class="a-letter-space"></span> </td> <td class="a-span10"> <a class="a-link-normal" title="12% des commentaires ont reçu 2 étoiles" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_hist_2?ie=UTF8&filterByStar=two_star&showViewpoints=0"><div class="a-meter" aria-label="12%"><div class="a-meter-bar" style="width: 12%;"></div></div></a> </td> <td class="a-nowrap"> <span class="a-letter-space"></span><span class="a-size-small">12%</span> </td> </tr> <tr class="a-histogram-row"> <td class="a-nowrap"> <span class="a-size-small">1 étoile</span> <span class="a-letter-space"></span> </td> <td class="a-span10"> <div class="a-meter" aria-label="0%"><div class="a-meter-bar" style="width: 0%;"></div></div> </td> <td class="a-nowrap"> <span class="a-letter-space"></span><span class="a-size-small">0%</span> </td> </tr> </table> <div class="a-section a-spacing-none a-text-center"> <a class="a-size-small a-link-emphasis" href="https://www.amazon.fr/product-reviews/B01N05ZMTK/ref=acr_dpx_see_all?ie=UTF8&showViewpoints=1"> Consulter les 17 commentaires </a> </div> </div> </div></div> EOD; $dom = new DOMDocument; libxml_use_internal_errors(true); $dom->loadHTML($html); $xp = new DOMXPath($dom); $stars = explode(' ', ltrim($xp->evaluate('string(//span[@class="a-size-base a-color-secondary"])')))[0]; echo $stars;

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.5.10.0030.00617.04
8.5.00.0090.01520.38
8.4.150.0010.00214.05
8.4.140.0170.00518.19
8.4.130.0110.01018.44
8.4.120.0110.00922.86
8.4.110.0070.00219.31
8.4.100.0090.01219.28
8.4.90.0140.00720.81
8.4.80.0080.00919.27
8.4.70.0110.00919.15
8.4.60.0140.00821.02
8.4.50.0110.01019.28
8.4.40.0070.00318.31
8.4.30.0030.01519.73
8.4.20.0110.01118.11
8.4.10.0100.01018.13
8.3.280.0030.00014.05
8.3.270.0130.00916.79
8.3.260.0090.01016.96
8.3.250.0060.00319.55
8.3.240.0050.00418.64
8.3.230.0130.00617.60
8.3.220.0110.00519.21
8.3.210.0130.00916.75
8.3.200.0120.00716.81
8.3.190.0100.01017.11
8.3.180.0060.00317.21
8.3.170.0100.01019.22
8.3.160.0030.01520.41
8.3.150.0170.00317.21
8.3.140.0060.00317.03
8.3.130.0090.00018.59
8.3.120.0060.01319.07
8.3.110.0050.00520.94
8.3.100.0130.00724.06
8.3.90.0070.00726.77
8.3.80.0060.00318.68
8.3.70.0110.01117.00
8.3.60.0120.00618.81
8.3.50.0070.00618.54
8.3.40.0110.00419.62
8.3.30.0090.00619.13
8.3.20.0040.00422.40
8.3.10.0080.00024.04
8.3.00.0080.00024.11
8.2.290.0110.00819.72
8.2.280.0120.00818.70
8.2.270.0000.01017.51
8.2.260.0050.00518.65
8.2.250.0060.00317.20
8.2.240.0090.00617.79
8.2.230.0030.00722.58
8.2.220.0100.00037.54
8.2.210.0030.00626.77
8.2.200.0060.00318.67
8.2.190.0070.01117.13
8.2.180.0060.00917.25
8.2.170.0150.00022.96
8.2.160.0070.01420.35
8.2.150.0040.00424.18
8.2.140.0000.00924.66
8.2.130.0050.00321.41
8.2.120.0030.00626.35
8.2.110.0070.00320.88
8.2.100.0040.01118.34
8.2.90.0050.00519.71
8.2.80.0060.00318.00
8.2.70.0040.00418.41
8.2.60.0060.00318.54
8.2.50.0000.00818.53
8.2.40.0050.00319.72
8.2.30.0040.00419.83
8.2.20.0040.00418.60
8.2.10.0030.00518.67
8.2.00.0000.00819.79
8.1.330.0110.00818.61
8.1.320.0120.00816.35
8.1.310.0080.00018.71
8.1.300.0030.00618.60
8.1.290.0070.00430.84
8.1.280.0120.00325.92
8.1.270.0000.00822.63
8.1.260.0120.00026.35
8.1.250.0080.00028.09
8.1.240.0030.00622.59
8.1.230.0060.00619.92
8.1.220.0040.00418.14
8.1.210.0050.00318.77
8.1.200.0110.00017.73
8.1.190.0040.00417.60
8.1.180.0050.00318.10
8.1.170.0080.00018.96
8.1.160.0030.00619.14
8.1.150.0040.00419.38
8.1.140.0040.00418.26
8.1.130.0000.00721.08
8.1.120.0000.00817.68
8.1.110.0060.00317.88
8.1.100.0040.00417.88
8.1.90.0040.00417.76
8.1.80.0050.00517.72
8.1.70.0040.00417.82
8.1.60.0000.00818.00
8.1.50.0080.00017.91
8.1.40.0000.00817.77
8.1.30.0040.00418.09
8.1.20.0120.00018.07
8.1.10.0000.00817.92
8.1.00.0060.00317.89
8.0.300.0040.00418.77
8.0.290.0060.00317.13
8.0.280.0070.00018.76
8.0.270.0070.00017.64
8.0.260.0000.00717.65
8.0.250.0000.00717.38
8.0.240.0090.00017.30
8.0.230.0000.00717.40
8.0.220.0040.00417.33
8.0.210.0040.00417.21
8.0.200.0030.00317.24
8.0.190.0000.00817.33
8.0.180.0000.00717.20
8.0.170.0030.00617.25
8.0.160.0040.00417.19
8.0.150.0000.00817.20
8.0.140.0000.00817.18
8.0.130.0060.00013.77
8.0.120.0050.00317.21
8.0.110.0050.00317.19
8.0.100.0030.00517.21
8.0.90.0000.00717.22
8.0.80.0030.01917.27
8.0.70.0040.00417.41
8.0.60.0000.00817.18
8.0.50.0080.00017.11
8.0.30.0130.00617.56
8.0.20.0120.00717.48
8.0.10.0040.00417.53
8.0.00.0130.00817.20
7.4.330.0050.00015.55
7.4.320.0030.00316.77
7.4.300.0040.00416.93
7.4.290.0040.00416.83
7.4.280.0030.00616.92
7.4.270.0050.00216.72
7.4.260.0040.00716.84
7.4.250.0030.00616.66
7.4.240.0000.00716.93
7.4.230.0000.00716.74
7.4.220.0020.00517.04
7.4.210.0070.00816.82
7.4.200.0030.00516.98
7.4.160.0110.00516.86
7.4.140.0100.00917.86
7.4.130.0090.01716.95
7.4.120.0080.01016.85
7.4.110.0070.01116.83
7.4.100.0090.01216.74
7.4.90.0140.00316.90
7.4.80.0120.00819.39
7.4.70.0030.01316.95
7.4.60.0080.00816.73
7.4.50.0070.01116.99
7.4.40.0110.00616.93
7.4.00.0030.00915.13
7.3.330.0000.00513.44
7.3.320.0000.00613.54
7.3.310.0070.00016.55
7.3.300.0000.00716.71
7.3.290.0000.00716.65
7.3.280.0100.00816.72
7.3.260.0140.00516.79
7.3.240.0090.00916.73
7.3.230.0140.01116.88
7.3.210.0110.01116.72
7.3.200.0100.00716.84
7.3.190.0100.00716.66
7.3.180.0100.01016.70
7.3.170.0120.01216.90
7.3.160.0030.01316.79
7.3.10.0070.00316.67
7.3.00.0030.00816.83
7.2.330.0000.01917.12
7.2.320.0130.00716.82
7.2.310.0070.01317.09
7.2.300.0110.00616.89
7.2.290.0100.00717.12
7.2.130.0040.00916.98
7.2.120.0060.00816.97
7.2.110.0100.00616.82
7.2.100.0050.00516.99
7.2.90.0050.00816.99
7.2.80.0070.00716.95
7.2.70.0070.00416.98
7.2.60.0060.00717.04
7.2.50.0050.00916.85
7.2.40.1890.01017.58
7.2.30.0570.00917.21
7.2.20.0050.01117.25
7.2.10.0080.00517.31
7.2.00.0060.00917.37
7.1.250.0050.00416.02
7.1.200.0000.00716.05
7.1.160.3760.00816.61
7.1.150.4080.01116.82
7.1.140.0050.01416.83
7.1.130.0080.00917.05
7.1.120.0070.01016.74
7.1.110.0140.00916.41
7.1.100.5990.00916.59
7.1.90.0100.00616.36
7.1.80.5000.00916.32
7.1.70.6700.01015.42
7.1.60.7650.01433.11
7.1.50.5990.01133.14
7.1.40.6340.01632.86
7.1.30.5570.01232.88
7.1.20.8170.01432.86
7.1.10.8850.01114.91
7.1.00.3340.00715.10

preferences:
37.51 ms | 403 KiB | 5 Q