3v4l.org

run code in 300+ PHP versions simultaneously
<?php $currencies = [ 'USD', 'BTC', 'DASH', 'LTC', 'SC', 'STEEM', 'WAVES', 'SNGLS', '1ST', 'BQX', 'ETH', 'PTOY', 'XAUR', ]; $input = [ "BTCUSD", "DASHBTC", "DOGEUSD", "LTCBTC", "LTCUSD", "SCBTC", "STEEMBTC", "WAVESBTC", "SNGLSBTC", "1STBTC", "DASHUSD", "BQXETH", "PTOYETH", "XAURETH", "BTCUSDT", ]; $output=[]; function filterCurrency($doubleCurrency, $key){ global $output; global $currencies; foreach($currencies as $currency){ $pattern = '/^'.$currency. '/'; preg_match($pattern, $doubleCurrency, $matches); if(array_key_exists(0, $matches)){ $output[]=$matches[0]; } } } array_walk_recursive($input, 'filterCurrency'); var_dump($output);

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.4.120.0110.00620.61
8.4.110.0150.00518.88
8.4.100.0140.00618.06
8.4.90.0090.01018.42
8.4.80.0120.00918.06
8.4.70.0110.01118.01
8.4.60.0120.00818.97
8.4.50.0120.00720.74
8.4.40.0120.00917.88
8.4.30.0150.00617.87
8.4.20.0100.01019.84
8.4.10.0060.00317.99
8.3.250.0110.00918.86
8.3.240.0120.00816.81
8.3.230.0080.01116.43
8.3.220.0140.00417.21
8.3.210.0040.00321.13
8.3.200.0110.00716.64
8.3.190.0110.00817.19
8.3.180.0070.00416.78
8.3.170.0120.00618.86
8.3.160.0000.00816.74
8.3.150.0070.01120.64
8.3.140.0060.01316.81
8.3.130.0070.00418.53
8.3.120.0030.00618.97
8.3.110.0030.00520.94
8.3.100.0000.00924.06
8.3.90.0080.00018.61
8.3.80.0090.00017.00
8.3.70.0110.00716.63
8.3.60.0090.00618.38
8.3.50.0090.00419.45
8.3.40.0130.00619.10
8.3.30.0090.00618.89
8.3.20.0040.00420.36
8.3.10.0040.00420.78
8.3.00.0070.00021.76
8.2.290.0130.00620.25
8.2.280.0140.00718.46
8.2.270.0040.01517.13
8.2.260.0150.00320.01
8.2.250.0080.00016.64
8.2.240.0050.00519.18
8.2.230.0110.00022.58
8.2.220.0130.00337.54
8.2.210.0080.00026.77
8.2.200.0000.00916.75
8.2.190.0070.01516.63
8.2.180.0150.00018.66
8.2.170.0080.00822.96
8.2.160.0110.00420.39
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0040.00420.47
8.2.120.0030.00526.35
8.2.110.0090.00022.38
8.2.100.0090.00317.97
8.2.90.0040.00417.97
8.2.80.0040.00417.88
8.2.70.0040.00417.75
8.2.60.0050.00318.05
8.2.50.0000.00918.07
8.2.40.0060.00320.07
8.2.30.0040.00418.03
8.2.20.0070.00018.03
8.2.10.0040.00418.22
8.2.00.0040.00418.11
8.1.330.0110.00921.92
8.1.320.0100.01016.38
8.1.310.0090.00918.64
8.1.300.0090.00318.10
8.1.290.0030.00618.88
8.1.280.0030.01625.92
8.1.270.0040.00422.19
8.1.260.0000.00826.35
8.1.250.0000.00828.09
8.1.240.0100.01023.88
8.1.230.0070.00721.04
8.1.220.0040.00417.78
8.1.210.0040.00419.04
8.1.200.0060.00317.48
8.1.190.0050.00517.48
8.1.180.0000.00818.10
8.1.170.0000.01018.78
8.1.160.0080.00018.80
8.1.150.0040.00418.89
8.1.140.0040.00419.10
8.1.130.0040.00418.91
8.1.120.0000.00717.63
8.1.110.0040.00417.58
8.1.100.0000.00917.55
8.1.90.0050.00317.63
8.1.80.0080.00017.60
8.1.70.0070.00017.45
8.1.60.0000.00817.64
8.1.50.0060.00317.67
8.1.40.0000.00817.63
8.1.30.0050.00317.81
8.1.20.0000.00917.77
8.1.10.0030.00517.63
8.1.00.0050.00317.58
8.0.300.0040.00420.03
8.0.290.0000.00716.75
8.0.280.0040.00418.52
8.0.270.0040.00417.29
8.0.260.0000.00716.98
8.0.250.0040.00417.13
8.0.240.0040.00417.04
8.0.230.0080.00016.98
8.0.220.0000.00816.94
8.0.210.0000.00817.02
8.0.200.0000.00717.08
8.0.190.0030.00617.17
8.0.180.0000.00716.93
8.0.170.0040.00416.96
8.0.160.0040.00417.07
8.0.150.0000.00716.94
8.0.140.0040.00417.02
8.0.130.0000.00913.49
8.0.120.0040.00416.89
8.0.110.0020.00517.04
8.0.100.0040.00417.03
8.0.90.0040.00416.99
8.0.80.0110.01217.07
8.0.70.0040.00416.93
8.0.60.0000.00716.93
8.0.50.0040.00417.09
8.0.30.0140.00617.39
8.0.20.0140.00917.41
8.0.10.0040.00417.11
8.0.00.0130.00717.02
7.4.330.0050.00015.55
7.4.320.0070.00016.83
7.4.300.0000.00616.74
7.4.290.0050.00316.80
7.4.280.0000.01016.70
7.4.270.0000.00816.73
7.4.260.0110.00016.77
7.4.250.0040.00416.63
7.4.240.0000.00816.74
7.4.230.0050.00216.89
7.4.220.0030.00616.74
7.4.210.0030.01716.93
7.4.200.0080.00016.90
7.4.160.0130.00616.72
7.4.150.0070.01117.40
7.4.140.0120.01117.86
7.4.130.0160.00616.55
7.4.120.0100.01016.73
7.4.110.0060.01216.73
7.4.100.0070.01116.57
7.4.90.0070.01116.64
7.4.80.0060.01219.39
7.4.70.0160.00516.73
7.4.60.0080.00816.73
7.4.50.0000.01316.57
7.4.40.0210.00316.54
7.4.30.0120.00416.77
7.4.00.0090.00915.09
7.3.330.0050.00013.37
7.3.320.0000.00513.38
7.3.310.0030.00316.34
7.3.300.0040.00416.40
7.3.290.0090.00916.44
7.3.280.0060.00916.45
7.3.270.0110.00817.40
7.3.260.0100.01016.54
7.3.250.0100.00816.74
7.3.240.0130.00916.67
7.3.230.0060.01716.82
7.3.210.0090.00916.53
7.3.200.0040.01416.61
7.3.190.0070.01116.53
7.3.180.0090.00916.60
7.3.170.0050.01116.59
7.3.160.0140.00916.57
7.3.120.0070.01315.29
7.3.110.0070.01014.86
7.3.100.0000.01315.25
7.3.90.0070.01014.98
7.3.80.0080.00414.93
7.3.70.0110.00714.91
7.3.60.0080.00815.06
7.3.50.0070.00314.57
7.3.40.0080.00415.03
7.3.30.0070.00315.04
7.3.20.0040.01116.89
7.3.10.0020.01316.91
7.3.00.0080.00516.95
7.2.330.0060.01516.96
7.2.320.0140.00416.85
7.2.310.0150.00416.84
7.2.300.0070.01016.69
7.2.290.0070.01116.84
7.2.250.0120.00615.32
7.2.240.0130.00715.48
7.2.230.0060.00915.35
7.2.220.0060.01215.18
7.2.210.0070.00715.12
7.2.200.0030.00715.16
7.2.190.0090.00615.37
7.2.180.0030.00915.09
7.2.170.0030.01015.21
7.2.160.0070.01015.36
7.2.150.0080.00416.97
7.2.140.0070.00717.13
7.2.130.0020.01217.03
7.2.120.0050.00917.01
7.2.110.0060.00817.11
7.2.100.0070.00717.17
7.2.90.0060.00917.03
7.2.80.0050.01017.04
7.2.70.0050.00817.23
7.2.60.0100.00916.95
7.2.50.0050.01117.08
7.2.40.0080.00617.11
7.2.30.0030.01117.23
7.2.20.0080.00617.17
7.2.10.0090.00716.97
7.2.00.0080.00717.94
7.1.330.0100.00315.70
7.1.320.0090.00615.81
7.1.310.0110.00415.95
7.1.300.0100.00315.77
7.1.290.0080.00416.14
7.1.280.0070.01015.99
7.1.270.0100.00715.84
7.1.260.0070.00716.20
7.1.250.0080.00316.12
7.1.200.0060.00615.91
7.1.120.0030.00819.09
7.1.110.0060.00618.56
7.1.100.0000.01018.28
7.1.90.0000.01018.32
7.1.80.0040.00418.33
7.1.70.0030.00617.42
7.1.60.0230.00034.73
7.1.50.0120.00934.40
7.1.40.0130.01034.32
7.1.30.0140.01034.11
7.1.20.0160.00634.47
7.1.10.0060.00316.71
7.1.00.0070.00316.88

preferences:
67.66 ms | 403 KiB | 5 Q