3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ 0 => [ "user_type" => 'Manager', "total_count" => 4, ], 1 => [ "user_type" => 'Trainee', "total_count" => 3, ] ]; $array_column = array_column($array, 'total_count', 'user_type'); //Create new array like below $add_array = array('Manager'=>'0', 'Director'=>'0', 'Trainee'=>'0',); //using array_merge merge add_array and array_column $new_array = array_merge($add_array, $array_column); //using array_walk_recursive get the requird result array_walk_recursive($new_array, function($item, $key) use (&$final_array){ $final_array['labels'][]=$key; $final_array['dataset'][]=$item; }); echo "<pre>"; print_r($final_array); ?>

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.0140.00624.03
8.4.110.0100.00923.22
8.4.100.0050.00419.08
8.4.90.0130.00718.88
8.4.80.0070.01218.87
8.4.70.0100.00818.16
8.4.60.0120.00918.84
8.4.50.0060.00418.62
8.4.40.0030.00717.53
8.4.30.0190.00020.41
8.4.20.0080.01120.59
8.4.10.0070.00417.92
8.3.250.0080.00918.84
8.3.240.0080.00917.19
8.3.230.0110.00717.33
8.3.220.0080.01018.97
8.3.210.0140.00516.55
8.3.200.0030.00516.40
8.3.190.0120.00618.90
8.3.180.0100.00618.26
8.3.170.0110.00717.18
8.3.160.0050.00318.37
8.3.150.0120.00616.70
8.3.140.0110.00416.78
8.3.130.0040.00416.54
8.3.120.0040.00418.90
8.3.110.0040.00816.69
8.3.100.0030.00716.48
8.3.90.0050.00318.21
8.3.80.0030.00716.63
8.3.70.0130.01016.58
8.3.60.0120.00916.50
8.3.50.0170.00921.96
8.3.40.0180.00318.81
8.3.30.0140.00018.67
8.3.20.0040.00421.85
8.3.10.0040.00420.20
8.3.00.0050.00223.70
8.2.290.0110.00720.75
8.2.280.0070.01218.50
8.2.270.0040.01417.18
8.2.260.0160.00316.55
8.2.250.0040.01118.52
8.2.240.0110.00419.04
8.2.230.0040.00420.94
8.2.220.0060.00324.06
8.2.210.0070.00726.77
8.2.200.0040.00416.50
8.2.190.0040.01216.75
8.2.180.0070.00718.29
8.2.170.0110.00422.96
8.2.160.0160.00321.97
8.2.150.0040.00424.18
8.2.140.0060.00324.66
8.2.130.0040.00426.16
8.2.120.0040.00426.16
8.2.110.0100.00021.03
8.2.100.0080.00417.72
8.2.90.0080.00022.33
8.2.80.0040.00419.21
8.2.70.0000.00818.05
8.2.60.0030.00618.16
8.2.50.0090.00018.10
8.2.40.0040.00419.42
8.2.30.0080.00019.32
8.2.20.0000.00818.02
8.2.10.0050.00219.37
8.2.00.0040.00419.39
8.1.330.0090.00922.19
8.1.320.0100.00918.15
8.1.310.0070.01118.21
8.1.300.0080.00020.22
8.1.290.0060.00318.88
8.1.280.0100.01025.92
8.1.270.0000.00722.19
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0030.00722.81
8.1.230.0100.00020.88
8.1.220.0040.00417.74
8.1.210.0030.00618.99
8.1.200.0040.00417.35
8.1.190.0000.00817.48
8.1.180.0000.00918.10
8.1.170.0040.00418.74
8.1.160.0080.00020.67
8.1.150.0050.00218.95
8.1.140.0000.00720.83
8.1.130.0000.00721.88
8.1.120.0000.01017.54
8.1.110.0040.00417.43
8.1.100.0030.00517.39
8.1.90.0000.00717.47
8.1.80.0120.00017.51
8.1.70.0000.00717.46
8.1.60.0000.00817.59
8.1.50.0060.00317.53
8.1.40.0040.00417.56
8.1.30.0030.00517.59
8.1.20.0030.00817.64
8.1.10.0030.00617.53
8.1.00.0030.00617.49
8.0.300.0060.00319.89
8.0.290.0080.00016.75
8.0.280.0030.00318.40
8.0.270.0000.00717.34
8.0.260.0030.00320.01
8.0.250.0030.00316.98
8.0.240.0040.00416.99
8.0.230.0000.00716.97
8.0.220.0070.00016.93
8.0.210.0030.00316.87
8.0.200.0030.00316.95
8.0.190.0040.00416.88
8.0.180.0080.00016.88
8.0.170.0030.00516.95
8.0.160.0050.00316.96
8.0.150.0080.00016.74
8.0.140.0030.00616.75
8.0.130.0060.00013.34
8.0.120.0000.01016.87
8.0.110.0080.00016.90
8.0.100.0070.00016.79
8.0.90.0040.00416.93
8.0.80.0080.00616.83
8.0.70.0000.00716.96
8.0.60.0000.00716.82
8.0.50.0040.00417.02
8.0.30.0140.00617.28
8.0.20.0170.00717.35
8.0.10.0040.00417.02
8.0.00.0100.00816.84
7.4.330.0020.00215.55
7.4.320.0000.00716.54
7.4.300.0060.00016.47
7.4.290.0040.00416.43
7.4.280.0040.00416.53
7.4.270.0000.00816.61
7.4.260.0030.00313.32
7.4.250.0030.00316.63
7.4.240.0030.00316.54
7.4.230.0030.00316.62
7.4.220.0030.00316.61
7.4.210.0070.01016.55
7.4.200.0070.00016.33
7.4.140.0030.01517.86
7.4.130.0100.00716.64
7.4.120.0170.00016.75
7.4.110.0100.01316.61
7.4.100.0060.01216.42
7.4.90.0060.01116.48
7.4.80.0070.01319.39
7.4.70.0120.01316.57
7.4.60.0110.00816.50
7.4.50.0110.00316.18
7.4.40.0040.01216.52
7.4.10.0000.02116.25
7.4.00.0060.01115.73
7.3.330.0030.00316.38
7.3.320.0000.00613.38
7.3.310.0000.00716.38
7.3.300.0000.00716.29
7.3.290.0090.00516.38
7.3.280.0050.01316.34
7.3.260.0120.00816.40
7.3.240.0110.00716.43
7.3.230.0090.00916.30
7.3.210.0070.01016.57
7.3.200.0030.01316.27
7.3.190.0170.00016.48
7.3.180.0160.00316.36
7.3.170.0060.00916.40
7.3.160.0100.00716.46
7.3.130.0040.01416.42
7.3.120.0060.01316.39
7.3.110.0070.00716.67
7.3.100.0060.01316.29
7.3.90.0120.00316.25
7.3.80.0000.01216.58
7.3.70.0050.00715.62
7.3.60.0050.00815.54
7.3.50.0090.00315.63
7.3.40.0080.00515.47
7.3.30.0050.00915.60
7.3.20.0090.00616.36
7.3.10.0140.00316.50
7.3.00.0630.00516.34
7.2.330.0030.01316.68
7.2.320.0130.00316.77
7.2.310.0040.01416.48
7.2.300.0000.01616.77
7.2.290.0070.01016.63
7.2.260.0100.01016.75
7.2.250.0070.01416.51
7.2.240.0070.00716.76
7.2.230.0130.00316.49
7.2.220.0040.01516.71
7.2.210.0060.00616.40
7.2.200.0020.01315.74
7.2.190.0060.01115.77
7.2.180.0080.00315.87
7.2.170.0060.00715.78
7.2.160.0090.00615.85
7.2.150.0080.00916.66
7.2.140.0080.00716.80
7.2.130.0070.00816.58
7.2.120.0080.00916.72
7.2.110.0060.00916.75
7.2.100.0060.00916.86
7.2.90.0100.00916.66
7.2.80.0120.00616.95
7.2.70.0070.00816.62
7.2.60.0140.00216.61
7.2.50.0130.00916.69
7.2.40.0080.01016.77
7.2.30.0120.00916.71
7.2.20.0100.00716.76
7.2.10.0090.00716.69
7.2.00.0080.00716.69
7.1.330.0120.00617.35
7.1.320.0060.00917.49
7.1.310.0100.00617.18
7.1.300.0080.00515.55
7.1.290.0090.00515.55
7.1.280.0060.00815.65
7.1.270.0050.00815.67
7.1.260.0100.00615.67
7.1.250.0120.00615.64
7.1.240.0060.00317.39
7.1.230.0030.00617.44
7.1.220.0100.01017.30
7.1.210.0140.00717.22
7.1.200.0040.01517.31
7.1.190.0100.00717.36
7.1.180.0070.00717.28
7.1.170.0110.00417.41
7.1.160.0080.00817.39
7.1.150.0030.01017.20
7.1.140.0140.00417.38
7.1.130.0030.01017.48
7.1.120.0060.00617.20
7.1.110.0030.01217.41
7.1.100.0080.00817.38
7.1.90.0120.00617.21
7.1.80.0040.01217.27
7.1.70.0030.01417.35
7.1.60.0060.01217.28
7.1.50.0060.00917.46
7.1.40.0030.01317.44
7.1.30.0120.00617.49
7.1.20.0090.00317.41
7.1.10.0100.00717.47
7.1.00.0140.00017.13

preferences:
28.36 ms | 403 KiB | 5 Q