3v4l.org

run code in 300+ PHP versions simultaneously
<?php $board = array( array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 1, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), array( 0, 0, 0, 0, 0, 0, 0, 0 ), ); function array_column(array $input, $columnKey, $indexKey = null) { $array = array(); foreach ($input as $value) { if ( ! isset($value[$columnKey])) { trigger_error("Key \"$columnKey\" does not exist in array"); return false; } if (is_null($indexKey)) { $array[] = $value[$columnKey]; } else { if ( ! isset($value[$indexKey])) { trigger_error("Key \"$indexKey\" does not exist in array"); return false; } if ( ! is_scalar($value[$indexKey])) { trigger_error("Key \"$indexKey\" does not contain scalar value"); return false; } $array[$value[$indexKey]] = $value[$columnKey]; } } return $array; } echo array_sum(array_column($board, 2));

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)
5.4.450.0130.06019.38
5.4.440.0830.06019.57
5.4.430.0230.06319.35
5.4.420.0930.05319.48
5.4.410.1170.06719.26
5.4.400.1200.05319.28
5.4.390.1170.06319.29
5.4.380.0100.05718.52
5.4.370.0130.05018.48
5.4.360.0100.05318.84
5.4.350.0300.06018.79
5.4.340.0030.06318.79
5.4.320.0090.03812.51
5.4.310.0080.05012.51
5.4.300.0110.03612.52
5.4.290.0060.05412.51
5.4.280.0070.05912.41
5.4.270.0170.05712.41
5.4.260.0150.08212.41
5.4.250.0060.05412.41
5.4.240.0110.03912.41
5.4.230.0120.04612.40
5.4.220.0080.05512.41
5.4.210.0070.05512.40
5.4.200.0120.06812.41
5.4.190.0060.07612.40
5.4.180.0060.06512.40
5.4.170.0130.05712.41
5.4.160.0090.05812.41
5.4.150.0110.06012.40
5.4.140.0110.05512.08
5.4.130.0090.06112.07
5.4.120.0090.06212.02
5.4.110.0120.05712.02
5.4.100.0110.04912.02
5.4.90.0080.05712.02
5.4.80.0090.05512.02
5.4.70.0080.03612.02
5.4.60.0080.03712.02
5.4.50.0080.04212.02
5.4.40.0150.04712.01
5.4.30.0140.06812.01
5.4.20.0080.06612.00
5.4.10.0090.06812.01
5.4.00.0070.04911.50
5.3.290.0040.04512.80
5.3.280.0090.04812.71
5.3.270.0070.05612.72
5.3.260.0050.05212.72
5.3.250.0110.07612.72
5.3.240.0120.06112.72
5.3.230.0060.06012.71
5.3.220.0070.05412.68
5.3.210.0080.05212.68
5.3.200.0090.05312.68
5.3.190.0070.05412.68
5.3.180.0110.06812.67
5.3.170.0080.05412.67
5.3.160.0110.06912.68
5.3.150.0080.06012.68
5.3.140.0090.05612.66
5.3.130.0100.05712.66
5.3.120.0110.04712.66
5.3.110.0110.04712.66
5.3.100.0120.04112.14
5.3.90.0110.04712.12
5.3.80.0130.05012.11
5.3.70.0050.05212.11
5.3.60.0060.04412.10
5.3.50.0080.05312.04
5.3.40.0100.05112.05
5.3.30.0080.06012.01
5.3.20.0090.06911.79
5.3.10.0140.05011.75
5.3.00.0100.05711.74

preferences:
138.98 ms | 1394 KiB | 7 Q