3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $array = [ [ 'a' => 1, 'b' => 2, 'c' => 3], [ 'a' => 4, 'b' => 5, 'c' => 6], [ 'a' => 7, 'b' => 8, 'c' => 9] ]; $column = array_column($array, 'a'); foreach ($array as &$val) { unset($val['a']); } // ПРОБЛЕМА РЕШЕНА for ($i = 0; $i < 3; ++$i) { echo implode(', ', $array[i]) . "\n"; } // !!! if (!empty($array)) { echo ' _______' . PHP_EOL . '| '; foreach ($array[0] as $key => $val) { echo $key . ' | '; } echo PHP_EOL . ' -------' . PHP_EOL; foreach ($array as $val) { echo '| '; foreach($val as $key => $veryVal) { echo $veryVal . ' | '; } echo PHP_EOL; } echo ' -------'; }

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).
Note: hhvm uses a JIT which only kicks in after a few runs. Since we run scripts only once, hhvm always runs slower.

VersionSystem time (s)User time (s)Memory (MiB)
7.3.0rc40.0230.00698.97
7.3.0rc30.0160.00616.70
7.3.0beta10.0070.00412.72
7.3.0alpha10.0040.00412.53
7.2.80.0060.00616.70
7.2.60.0030.01216.91
7.2.00.0000.00919.21
7.1.200.0070.00715.63
7.1.100.0050.00518.04
7.1.70.0040.00416.94
7.1.60.0030.02119.82
7.1.50.0100.00016.70
7.1.00.0000.08022.37
7.0.200.0060.00616.48
7.0.140.0000.07321.95
7.0.60.0130.07720.02
7.0.50.0070.05717.79
7.0.40.0100.08320.05
7.0.30.0330.04320.16
7.0.20.0170.04020.09
7.0.10.0100.06020.00
7.0.00.0070.04720.17
5.6.280.0070.07021.16
5.6.210.0130.07720.65
5.6.200.0100.08018.12
5.6.190.0000.04720.56
5.6.180.3770.04020.21
5.6.170.0270.07320.61
5.6.160.0070.04720.49
5.6.150.0070.08018.11
5.6.140.0070.06018.11
5.6.130.0070.04318.11
5.6.120.0230.06321.10
5.6.110.0130.08020.96
5.6.100.0070.08321.05
5.6.90.0130.08321.10
5.6.80.0100.07320.54
5.5.350.0100.04020.48
5.5.340.0100.04018.02
5.5.330.0070.08720.43
5.5.320.0330.04720.29
5.5.310.0300.07720.16
5.5.300.0000.04017.91
5.5.290.0030.08017.91
5.5.280.0000.04320.75
5.5.270.0070.08320.79
5.5.260.0170.08020.87
5.5.250.0130.07720.68
5.5.240.0130.07720.07
5.4.450.1900.04719.38
5.4.440.1900.03019.39
5.4.430.1700.04319.09
5.4.420.0370.05319.45
5.4.410.0100.03019.29
5.4.400.0030.07019.08
5.4.390.0370.04018.77
5.4.380.0170.05718.77
5.4.370.0400.03018.77
5.4.360.0200.03319.07
5.4.350.0270.02719.06
5.4.340.0200.05319.09
5.4.320.0230.03718.91
5.4.310.0430.07019.13
5.4.300.0130.04319.07
5.4.290.0230.03019.24
5.4.280.0130.04019.07
5.4.270.0200.04319.13
5.4.260.0200.03319.08
5.4.250.0170.03719.07
5.4.240.0170.03719.06
5.4.230.0270.04019.22
5.4.220.0170.04318.81
5.4.210.0200.03319.07
5.4.200.0130.04719.09
5.4.190.0230.03018.91
5.4.180.0170.04718.81
5.4.170.0170.03319.11
5.4.160.0170.04719.06
5.4.150.0230.04718.91
5.4.140.0200.06716.32
5.4.130.0230.04016.26
5.4.120.0200.03316.18
5.4.110.0170.04016.30
5.4.100.0130.07316.49
5.4.90.0170.03716.47
5.4.80.0170.03716.38
5.4.70.0200.03316.41
5.4.60.0270.07016.40
5.4.50.0130.04016.20
5.4.40.0170.07316.23
5.4.30.0270.05016.05
5.4.20.0200.07016.36
5.4.10.0200.06716.36
5.4.00.0170.04315.63
5.3.290.0130.04014.61
5.3.280.0200.07314.46
5.3.270.0200.06014.41
5.3.260.0230.06714.45
5.3.250.0200.03314.55
5.3.240.0230.07014.46
5.3.230.0130.04014.45
5.3.220.0270.03314.51
5.3.210.0270.06714.44
5.3.200.0230.04014.55
5.3.190.0300.06714.57
5.3.180.0170.07714.41
5.3.170.0170.04714.42
5.3.160.0230.04714.45
5.3.150.0200.05014.51
5.3.140.0200.06714.40
5.3.130.0200.04314.45
5.3.120.0170.07714.64
5.3.110.0130.06314.56
5.3.100.0100.04314.06
5.3.90.0270.06313.86
5.3.80.0300.03713.96
5.3.70.0230.07013.81
5.3.60.0170.05013.84
5.3.50.0230.03013.96
5.3.40.0170.07713.88
5.3.30.0130.04013.75
5.3.20.0200.06713.59
5.3.10.0230.06313.64
5.3.00.0230.04313.51
5.2.170.0170.05711.30
5.2.160.0100.03310.98
5.2.150.0270.05010.99
5.2.140.0200.04011.05
5.2.130.0130.03011.11
5.2.120.0170.05710.96
5.2.110.0170.05010.94
5.2.100.0230.05711.12
5.2.90.0200.02710.94
5.2.80.0330.03711.03
5.2.70.0200.05711.17
5.2.60.0170.06011.13
5.2.50.0130.04010.87
5.2.40.0130.03010.88
5.2.30.0030.03710.82
5.2.20.0130.02710.84
5.2.10.0100.04310.81
5.2.00.0100.03010.79
5.1.60.0170.0239.85
5.1.50.0130.0539.96
5.1.40.0170.0479.87
5.1.30.0130.03310.28
5.1.20.0070.03010.28
5.1.10.0170.0379.96
5.1.00.0170.0209.97
5.0.50.0070.0278.46
5.0.40.0130.0238.39
5.0.30.0030.0408.10
5.0.20.0070.0178.20
5.0.10.0030.0308.29
5.0.00.0070.0338.13
4.4.90.0030.0177.80
4.4.80.0030.0177.80
4.4.70.0070.0137.80
4.4.60.0070.0177.80
4.4.50.0070.0377.80
4.4.40.0070.0537.80
4.4.30.0070.0307.80
4.4.20.0170.0277.80
4.4.10.0130.0207.80
4.4.00.0130.0477.80
4.3.110.0100.0337.80
4.3.100.0130.0107.80
4.3.90.0070.0237.80
4.3.80.0070.0407.80
4.3.70.0070.0277.80
4.3.60.0070.0177.80
4.3.50.0130.0307.80
4.3.40.0100.0177.80
4.3.30.0000.0177.80
4.3.20.0070.0337.80
4.3.10.0000.0337.80
4.3.00.0000.0307.80