3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ [ ['color' => 'RED'], ['color' => 'BLUE'], ['color' => 'GREEN'] ], [ ['color' => 'RED'], ['color' => 'PURPLE'], ['color' => 'RED'] ] ]; $result = []; foreach ($array as $row) { $result[] = array_values(array_column($row, null, 'color')); } echo json_encode($result);

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.00.0160.00719.86
8.4.150.0020.00014.05
8.4.140.0110.00917.70
8.4.130.0100.00717.78
8.4.120.0120.00822.41
8.4.110.0130.00718.68
8.4.100.0020.00617.93
8.4.90.0110.00820.46
8.4.80.0080.00417.81
8.4.70.0110.01117.80
8.4.60.0090.00917.84
8.4.50.0170.00619.42
8.4.40.0190.00017.59
8.4.30.0150.00420.78
8.4.20.0100.00017.96
8.4.10.0130.00719.33
8.3.280.0020.00114.05
8.3.270.0090.01016.51
8.3.260.0120.00816.74
8.3.250.0070.00318.78
8.3.240.0070.00116.34
8.3.230.0100.00916.33
8.3.220.0110.00820.75
8.3.210.0110.00716.57
8.3.200.0070.00816.50
8.3.190.0080.01016.48
8.3.180.0110.00816.38
8.3.170.0090.00916.59
8.3.160.0150.00317.13
8.3.150.0190.00017.19
8.3.140.0200.00716.38
8.3.130.0040.00416.71
8.3.120.0090.00018.97
8.3.110.0060.00620.94
8.3.100.0040.00724.06
8.3.90.0070.00726.77
8.3.80.0040.00419.36
8.3.70.0100.00716.50
8.3.60.0160.00316.50
8.3.50.0000.01518.14
8.3.40.0030.01318.79
8.3.30.0120.00318.59
8.3.20.0020.00524.18
8.3.10.0080.00024.66
8.3.00.0040.00426.16
8.2.290.0080.01120.29
8.2.280.0050.00320.02
8.2.270.0070.01116.93
8.2.260.0000.00818.22
8.2.250.0120.00618.05
8.2.240.0050.00318.88
8.2.230.0030.00622.58
8.2.220.0080.00037.54
8.2.210.0130.00626.77
8.2.200.0090.00018.88
8.2.190.0070.00716.58
8.2.180.0100.01025.92
8.2.170.0100.01018.91
8.2.160.0100.00322.96
8.2.150.0050.00325.66
8.2.140.0040.00424.66
8.2.130.0000.00726.16
8.2.120.0000.00726.35
8.2.110.0090.00019.39
8.2.100.0110.00017.91
8.2.90.0060.00317.88
8.2.80.0040.00418.77
8.2.70.0050.00317.75
8.2.60.0050.00318.05
8.2.50.0060.00318.07
8.2.40.0040.00418.16
8.2.30.0000.00818.19
8.2.20.0070.00018.00
8.2.10.0040.00419.30
8.2.00.0070.00019.31
8.1.330.0050.00421.66
8.1.320.0130.00716.00
8.1.310.0140.00316.42
8.1.300.0030.00618.49
8.1.290.0090.00030.84
8.1.280.0100.00725.92
8.1.270.0030.00623.81
8.1.260.0020.00528.09
8.1.250.0060.00328.09
8.1.240.0060.00320.82
8.1.230.0070.00320.77
8.1.220.0050.00317.79
8.1.210.0000.00818.77
8.1.200.0030.00617.23
8.1.190.0030.00517.23
8.1.180.0000.00818.10
8.1.170.0000.00818.71
8.1.160.0050.00218.96
8.1.150.0070.00018.81
8.1.140.0050.00318.94
8.1.130.0000.00720.07
8.1.120.0030.00517.47
8.1.110.0000.00817.43
8.1.100.0040.00417.44
8.1.90.0040.00417.44
8.1.80.0000.00717.41
8.1.70.0000.00717.38
8.1.60.0060.00317.55
8.1.50.0030.00617.54
8.1.40.0000.00817.47
8.1.30.0080.00317.59
8.1.20.0040.00417.61
8.1.10.0040.00417.41
8.1.00.0040.00417.34
8.0.300.0040.00418.77
8.0.290.0030.00516.63
8.0.280.0000.00718.41
8.0.270.0070.00018.05
8.0.260.0030.00318.43
8.0.250.0000.00716.96
8.0.240.0080.00016.94
8.0.230.0040.00416.93
8.0.220.0040.00416.86
8.0.210.0070.00016.89
8.0.200.0000.00716.99
8.0.190.0030.00516.97
8.0.180.0020.00516.95
8.0.170.0070.00316.84
8.0.160.0000.00816.92
8.0.150.0000.00716.67
8.0.140.0030.00916.79
8.0.130.0050.00013.43
8.0.120.0030.00616.93
8.0.110.0070.00016.82
8.0.100.0000.00716.75
8.0.90.0070.00016.86
8.0.80.0040.01116.83
8.0.70.0000.00716.88
8.0.60.0070.00016.73
8.0.50.0000.00716.78
8.0.30.0080.00816.92
8.0.20.0200.00416.90
8.0.10.0280.00316.98
8.0.00.0230.01117.03
7.4.330.0000.00515.55
7.4.320.0000.00716.53
7.4.300.0060.00316.59
7.4.290.0070.00316.31
7.4.280.0040.00416.52
7.4.270.0070.00016.52
7.4.260.0050.00013.29
7.4.250.0030.00316.44
7.4.240.0000.00716.47
7.4.230.0070.00016.36
7.4.220.0030.00316.57
7.4.210.0110.00416.53
7.4.200.0040.00416.67
7.4.160.0160.00716.60
7.4.150.0230.00416.43
7.4.140.0230.00316.53
7.4.130.0180.01116.60
7.4.120.0280.01416.51
7.4.110.0180.01316.41
7.4.100.0250.00616.67
7.4.90.0230.00816.50
7.4.80.0270.00616.33
7.4.70.0170.01116.40
7.4.60.0210.00716.47
7.4.50.0280.00416.35
7.4.40.0200.01216.50
7.4.30.0160.00716.52
7.4.20.0190.00916.47
7.4.10.0230.01016.56
7.4.00.0170.00716.47
7.3.330.0050.00416.22
7.3.320.0030.00313.20
7.3.310.0000.00716.27
7.3.300.0000.00716.25
7.3.290.0080.00816.25
7.3.270.0130.01616.36
7.3.260.0230.00316.18
7.3.250.0310.00016.29
7.3.240.0300.00016.21
7.3.230.0190.01116.29
7.3.220.0260.00716.25
7.3.210.0250.00416.25
7.3.200.0200.00916.23
7.3.190.0190.01116.21
7.3.180.0240.00616.22
7.3.170.0310.00416.18
7.3.160.0160.01016.20
7.3.150.0170.01016.15
7.3.140.0150.01016.23
7.3.130.0260.00816.14
7.3.120.0250.00716.30
7.3.110.0200.00616.16
7.3.100.0210.00316.08
7.3.90.0210.00416.41
7.3.80.0180.01116.19
7.3.70.0290.00416.38
7.3.60.0180.01216.37
7.3.50.0260.00016.32
7.3.40.0130.01316.36
7.3.30.0160.00816.35
7.3.20.0290.00816.39
7.3.10.0180.00716.32
7.3.00.0510.01116.38

preferences:
162.96 ms | 403 KiB | 5 Q