3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = [ 'foo', 'foo', 'bar', 'baz', 'baz' ]; $arr2 = []; foreach ($arr as $v) { $lower = mb_strtolower($item, 'utf-8'); foreach ($arr2 as $v2) { $lower2 = mb_strtolower($item, 'utf-8'); if ($lower === $lower2) { continue 2; } } $arr2[] = $v; } var_dump($arr);

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.70.0100.01018.43
8.3.60.0030.01216.73
8.3.50.0170.00216.45
8.3.40.0090.00618.77
8.3.30.0040.01118.67
8.3.20.0050.00319.95
8.3.10.0040.00421.96
8.3.00.0070.00019.44
8.2.190.0150.00616.63
8.2.180.0000.01516.88
8.2.170.0140.00722.96
8.2.160.0060.00919.21
8.2.150.0030.00524.18
8.2.140.0040.00424.66
8.2.130.0000.00719.39
8.2.120.0000.00826.35
8.2.110.0060.00320.30
8.2.100.0100.00017.91
8.2.90.0030.00519.36
8.2.80.0040.00417.97
8.2.70.0060.00317.63
8.2.60.0040.00418.16
8.2.50.0060.00318.10
8.2.40.0030.00520.42
8.2.30.0070.00019.32
8.2.20.0000.00818.19
8.2.10.0000.00818.13
8.2.00.0000.00718.12
8.1.280.0110.00425.92
8.1.270.0070.00022.14
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0000.00922.74
8.1.230.0040.00719.07
8.1.220.0050.00317.79
8.1.210.0000.00818.77
8.1.200.0070.00317.35
8.1.190.0040.00417.23
8.1.180.0050.00318.10
8.1.170.0060.00318.65
8.1.160.0050.00218.99
8.1.150.0030.00518.88
8.1.140.0040.00419.64
8.1.130.0000.00718.83
8.1.120.0030.00517.55
8.1.110.0050.00317.54
8.1.100.0030.00617.52
8.1.90.0000.00817.50
8.1.80.0040.00417.53
8.1.70.0030.00317.42
8.1.60.0000.00717.54
8.1.50.0040.00417.57
8.1.40.0030.00817.45
8.1.30.0000.00817.71
8.1.20.0060.00317.57
8.1.10.0040.00417.63
8.1.00.0090.00017.51
8.0.300.0080.00018.77
8.0.290.0080.00016.75
8.0.280.0000.00718.49
8.0.270.0030.00317.32
8.0.260.0030.00316.88
8.0.250.0030.00317.07
8.0.240.0040.00417.07
8.0.230.0040.00416.98
8.0.220.0000.00716.99
8.0.210.0040.00416.90
8.0.200.0030.00317.06
8.0.190.0060.00317.13
8.0.180.0070.00017.07
8.0.170.0040.00417.00
8.0.160.0070.00016.96
8.0.150.0000.00817.00
8.0.140.0000.00716.98
8.0.130.0000.00813.45
8.0.120.0060.00316.87
8.0.110.0070.00016.79
8.0.100.0000.00717.00
8.0.90.0000.00717.06
8.0.80.0100.00717.00
8.0.70.0000.00717.01
8.0.60.0040.00416.92
8.0.50.0000.00717.00
8.0.30.0160.00717.23
8.0.20.0110.01017.40
8.0.10.0000.00817.11
8.0.00.0100.00716.91
7.4.330.0050.00015.55
7.4.320.0000.00616.50
7.4.300.0030.00316.51
7.4.290.0000.00816.58
7.4.280.0040.00316.57
7.4.270.0030.00316.65
7.4.260.0000.00716.61
7.4.250.0070.00016.52
7.4.240.0040.00416.71
7.4.230.0020.00516.77
7.4.220.0030.01416.62
7.4.210.0120.00416.67
7.4.200.0030.00316.69
7.4.160.0100.00816.41
7.4.150.0090.01517.40
7.4.140.0090.01017.86
7.4.130.0190.00616.64
7.4.120.0070.01016.59
7.4.110.0150.00416.57
7.4.100.0120.01216.68
7.4.90.0110.00616.46
7.4.80.0170.00019.39
7.4.70.0110.01116.66
7.4.60.0110.00516.56
7.4.50.0000.01416.59
7.4.40.0040.01216.73
7.4.30.0160.00316.70
7.4.00.0080.00314.97
7.3.330.0030.00313.20
7.3.320.0060.00013.43
7.3.310.0040.00316.21
7.3.300.0000.00716.47
7.3.290.0000.00716.41
7.3.280.0090.00716.45
7.3.270.0080.01217.40
7.3.260.0080.01016.50
7.3.250.0100.00716.43
7.3.240.0100.01016.46
7.3.230.0140.00316.33
7.3.210.0100.00616.63
7.3.200.0070.01016.35
7.3.190.0130.00416.52
7.3.180.0100.00816.39
7.3.170.0120.00916.57
7.3.160.0070.00816.63
7.2.330.0090.01716.56
7.2.320.0150.00316.53
7.2.310.0050.01216.61
7.2.300.0030.01416.85
7.2.290.0160.00316.61
7.2.60.0030.01016.70
7.2.00.0080.00819.16
7.1.200.0090.00015.86
7.1.100.0040.00818.19
7.1.70.0220.01315.35
7.1.60.0490.01133.42
7.1.50.0440.01633.21
7.1.40.0330.01032.67
7.1.30.0680.02332.51
7.1.20.0680.01332.70
7.1.10.0210.01414.61
7.1.00.0230.01115.04
7.0.200.0180.01615.15
7.0.190.0180.01515.00
7.0.180.0210.00914.39
7.0.170.0290.01114.63
7.0.160.0260.00814.54
7.0.150.0180.00514.41
7.0.140.0160.02014.46
7.0.130.0180.00914.66
7.0.120.0230.01614.78
7.0.110.0210.01014.70
7.0.100.0250.00914.57
7.0.90.0220.01114.35
7.0.80.0970.00714.53
7.0.70.0160.01314.68
7.0.60.0120.01514.34
7.0.50.0300.00914.48
7.0.40.0250.01114.57
7.0.30.0250.01114.82
7.0.20.0210.01414.52
7.0.10.0170.01614.54
7.0.00.0250.01114.55

preferences:
27.4 ms | 401 KiB | 5 Q