3v4l.org

run code in 500+ PHP versions simultaneously
<?php $arrays = array ( 'grinds' => array ( 0 => array ( 'id' => 16562, 'slug' => 'grinds', ), 1 => array ( 'id' => 16561, 'slug' => 'grinds', ), ), 'online-grinds' => array ( 0 => array ( 'id' => 16566, 'slug' => 'online-grinds', ), ), ); $result = []; foreach ($arrays as $key => $array) { $result[$key] = [ array_count_values(array_column($array, 'id')), array_count_values(array_column($array, 'slug')) ]; } print_r($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.30.0080.00821.06
8.5.20.0110.00619.63
8.5.10.0100.01116.73
8.5.00.0100.01219.99
8.4.180.0070.00419.54
8.4.170.0100.01120.47
8.4.160.0160.00820.63
8.4.150.0070.00616.89
8.4.140.0150.00717.64
8.4.130.0140.00618.51
8.4.120.0030.00622.06
8.4.110.0130.00818.78
8.4.100.0150.00717.89
8.4.90.0100.01020.33
8.4.80.0060.00420.34
8.4.70.0070.00918.99
8.4.60.0120.00720.45
8.4.50.0100.01018.54
8.4.40.0040.00419.28
8.4.30.0040.00419.36
8.4.20.0170.00320.59
8.4.10.0060.00317.57
8.3.300.0130.00719.26
8.3.290.0130.01120.72
8.3.280.0070.01418.18
8.3.270.0110.00816.41
8.3.260.0130.00716.53
8.3.250.0120.00717.05
8.3.240.0110.00816.59
8.3.230.0120.00616.48
8.3.220.0100.00819.05
8.3.210.0090.00616.61
8.3.200.0070.00216.40
8.3.190.0090.00617.01
8.3.180.0050.01219.05
8.3.170.0060.00918.77
8.3.160.0140.00416.64
8.3.150.0070.01017.36
8.3.140.0030.00616.55
8.3.130.0100.00318.43
8.3.120.0100.00018.88
8.3.110.0120.00420.94
8.3.100.0080.00024.06
8.3.90.0100.00026.77
8.3.80.0130.00017.97
8.3.70.0140.00416.75
8.3.60.0120.00618.31
8.3.50.0110.00618.85
8.3.40.0140.00718.69
8.3.30.0110.00418.73
8.3.20.0000.00721.83
8.3.10.0040.00423.66
8.3.00.0050.00323.65
8.2.300.0120.00920.23
8.2.290.0110.00817.20
8.2.280.0130.00618.41
8.2.270.0070.01116.59
8.2.260.0110.00718.67
8.2.250.0090.00018.32
8.2.240.0080.00018.78
8.2.230.0090.00622.58
8.2.220.0070.00337.54
8.2.210.0070.00726.77
8.2.200.0030.00616.36
8.2.190.0120.00916.58
8.2.180.0110.00418.26
8.2.170.0150.00322.96
8.2.160.0110.00420.38
8.2.150.0050.00324.18
8.2.140.0080.00024.66
8.2.130.0030.00526.16
8.2.120.0100.00017.93
8.2.110.0000.00921.16
8.2.100.0080.00417.91
8.2.90.0000.00817.84
8.2.80.0030.00618.03
8.2.70.0000.00817.93
8.2.60.0030.00618.34
8.2.50.0050.00318.10
8.2.40.0000.00719.30
8.2.30.0000.00719.34
8.2.20.0050.00318.12
8.2.10.0000.00720.67
8.2.00.0040.00419.34
8.1.340.0090.01120.14
8.1.330.0090.01116.04
8.1.320.0110.00718.13
8.1.310.0000.00916.52
8.1.300.0060.00316.32
8.1.290.0090.00330.84
8.1.280.0140.00725.92
8.1.270.0080.00018.96
8.1.260.0150.00026.35
8.1.250.0050.00328.09
8.1.240.0060.00324.00
8.1.230.0060.00622.75
8.1.220.0050.00317.74
8.1.210.0000.00819.93
8.1.200.0080.00417.47
8.1.190.0030.00517.23
8.1.180.0040.00418.10
8.1.170.0080.00018.50
8.1.160.0050.00218.95
8.1.150.0000.00718.85
8.1.140.0020.00523.92
8.1.130.0030.00320.14
8.1.120.0040.00417.46
8.1.110.0070.00017.48
8.1.100.0040.00417.49
8.1.90.0050.00317.48
8.1.80.0030.00717.43
8.1.70.0000.00717.45
8.1.60.0030.00517.58
8.1.50.0030.00617.41
8.1.40.0000.00717.44
8.1.30.0030.00617.67
8.1.20.0020.00517.63
8.1.10.0030.00617.48
8.1.00.0040.00417.52
8.0.300.0040.00421.90
8.0.290.0000.00816.63
8.0.280.0070.00018.41
8.0.270.0030.00416.74
8.0.260.0030.00518.37
8.0.250.0000.00716.92
8.0.240.0030.00516.86
8.0.230.0070.00016.86
8.0.220.0000.00716.79
8.0.210.0070.00016.88
8.0.200.0000.00616.94
8.0.190.0040.00416.99
8.0.180.0040.00416.88
8.0.170.0030.00716.92
8.0.160.0060.00316.73
8.0.150.0000.00816.82
8.0.140.0000.00716.89
8.0.130.0000.00613.27
8.0.120.0040.00416.85
8.0.110.0000.00716.90
8.0.100.0040.00416.77
8.0.90.0070.00016.76
8.0.80.0070.00916.88
8.0.70.0050.00316.78
8.0.60.0050.00216.76
8.0.50.0000.00816.73
8.0.30.0160.01817.04
8.0.20.0130.00617.40
8.0.10.0040.00416.87
8.0.00.0100.00816.89
7.4.330.0050.00016.79
7.4.320.0030.00316.51
7.4.300.0040.00416.49
7.4.290.0040.00416.42
7.4.280.0070.00016.44
7.4.270.0030.00316.41
7.4.260.0000.00716.63
7.4.250.0040.00416.48
7.4.240.0000.00816.51
7.4.230.0040.00416.63
7.4.220.0000.00816.53
7.4.210.0090.00816.54
7.4.200.0040.00416.62
7.4.140.0100.00817.86
7.4.130.0040.01516.34
7.4.120.0090.00916.48
7.4.110.0130.00316.34
7.4.100.0140.00716.42
7.4.90.0110.01216.40
7.4.80.0080.00919.39
7.4.70.0120.01216.62
7.4.60.0080.01116.49
7.4.50.0040.01516.48
7.4.40.0170.00016.68
7.4.00.0070.00914.93
7.3.330.0000.00513.24
7.3.320.0000.00513.22
7.3.310.0030.00316.31
7.3.300.0040.00416.42
7.3.290.0030.00316.40
7.3.280.0090.00616.32
7.3.260.0070.01116.38
7.3.240.0080.01016.44
7.3.230.0140.00316.59
7.3.210.0100.01016.43
7.3.200.0080.00816.54
7.3.190.0100.00716.44
7.3.180.0090.00616.35
7.3.170.0120.00616.28
7.3.160.0090.01216.44
7.3.120.0090.00914.88
7.3.110.0110.00714.73
7.3.100.0110.00314.86
7.3.90.0080.00315.04
7.3.80.0100.00314.88
7.3.70.0090.00014.93
7.3.60.0000.01014.66
7.3.50.0040.01114.92
7.3.40.0090.00614.76
7.3.30.0040.00714.66
7.3.20.0030.01416.67
7.3.10.0070.00316.74
7.3.00.0230.00815.75
7.2.330.0110.01116.38
7.2.320.0090.01316.82
7.2.310.0030.01316.57
7.2.300.0110.01116.64
7.2.290.0140.00316.35
7.2.250.0110.00715.18
7.2.240.0090.00614.98
7.2.230.0110.00714.62
7.2.220.0110.00014.95
7.2.210.0040.01114.91
7.2.200.0090.00315.06
7.2.190.0030.01014.73
7.2.180.0070.01114.89
7.2.170.0060.00314.82
7.2.130.0440.00414.78
7.2.120.0060.01314.91
7.2.110.0110.01114.77
7.2.100.0120.00314.82
7.2.90.0700.00314.64
7.2.80.0090.00614.53
7.2.70.0320.01015.04
7.2.60.0380.00314.96
7.2.50.0310.01015.02
7.2.40.0420.00314.86
7.2.30.0470.00314.97
7.2.20.0470.00715.13
7.2.10.0390.00715.07
7.2.00.0360.01015.12
7.1.330.0120.00315.83
7.1.320.0060.00915.98
7.1.310.0000.01515.82
7.1.300.0030.00715.72
7.1.290.0030.01015.77
7.1.280.0030.00715.87
7.1.270.0000.01316.05
7.1.260.0070.00415.75
7.1.250.0700.00713.87
7.0.330.0140.00413.65
5.6.380.0150.00014.20

preferences:
105.99 ms | 1634 KiB | 4 Q