3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = Array ( "1" => Array ( "0" => "16/03/2018", "1" => "Friday", "2" => "21.00", "3" => "Friendly Match", "4" => "Italy vs France", "5" => "Truesports HD", ), "2" => Array ( "0" => "17/03/2018", "1" => "Saturday", "2" => "15.30", "3" => "Friendly Match", "4" => "Italy vs Pakistan", "5" => "Truesports HD", ), "3" => Array ( "0" => "17/03/2018", "1" => "Saturday", "2" => "19.00", "3" => "Friendly Match", "4" => "Spain vs USA", "5" => "Truesports" ) ); $array_keys= array("date","day","time","type","value","tv"); $new_array = array(); foreach ($array as $key => $value) { $tmp_array = array(); foreach ($value as $key1 => $value1) { $tmp_array[$array_keys[$key1]] = $value1; } $new_array[] =$tmp_array; } echo json_encode($new_array, JSON_PRETTY_PRINT);

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.3.130.0040.00418.50
8.3.120.0080.00019.00
8.3.110.0090.00020.94
8.3.100.0040.00424.06
8.3.90.0000.00726.77
8.3.80.0030.00716.75
8.3.70.0140.00716.75
8.3.60.0040.01118.55
8.3.50.0110.00618.24
8.3.40.0110.00418.76
8.3.30.0110.00318.82
8.3.20.0040.00421.91
8.3.10.0050.00323.53
8.3.00.0040.00419.81
8.2.250.0080.00018.58
8.2.240.0040.01118.82
8.2.230.0040.00422.58
8.2.220.0060.00337.54
8.2.210.0070.00026.77
8.2.200.0040.00716.50
8.2.190.0120.00316.58
8.2.180.0070.01018.41
8.2.170.0160.00018.99
8.2.160.0110.00422.96
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0040.00420.39
8.2.120.0020.00526.35
8.2.110.0060.00320.46
8.2.100.0060.00617.72
8.2.90.0000.00822.24
8.2.80.0050.00317.97
8.2.70.0000.00818.03
8.2.60.0040.00417.75
8.2.50.0040.00418.28
8.2.40.0040.00422.29
8.2.30.0040.00419.50
8.2.20.0070.00018.00
8.2.10.0080.00017.85
8.2.00.0050.00318.04
8.1.300.0060.00317.93
8.1.290.0030.00618.88
8.1.280.0100.00725.92
8.1.270.0000.00723.96
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0060.00323.73
8.1.230.0070.00423.76
8.1.220.0040.00417.76
8.1.210.0000.00919.00
8.1.200.0080.00017.47
8.1.190.0030.00717.47
8.1.180.0040.00418.10
8.1.170.0040.00418.58
8.1.160.0040.00418.84
8.1.150.0030.00320.22
8.1.140.0000.00717.67
8.1.130.0030.00318.99
8.1.120.0030.00317.45
8.1.110.0040.00417.32
8.1.100.0040.00417.46
8.1.90.0080.00017.48
8.1.80.0040.00317.45
8.1.70.0040.00417.34
8.1.60.0040.00417.47
8.1.50.0040.00417.45
8.1.40.0000.00717.53
8.1.30.0050.00317.69
8.1.20.0000.00817.58
8.1.10.0030.00517.60
8.1.00.0050.00317.55
8.0.300.0040.00419.86
8.0.290.0040.00416.75
8.0.280.0050.00318.39
8.0.270.0070.00017.29
8.0.260.0040.00416.69
8.0.250.0080.00016.85
8.0.240.0050.00316.89
8.0.230.0050.00316.95
8.0.220.0000.00816.88
8.0.210.0070.00016.90
8.0.200.0030.00516.94
8.0.190.0000.01016.88
8.0.180.0070.00016.82
8.0.170.0040.00716.79
8.0.160.0000.00716.89
8.0.150.0040.00416.81
8.0.140.0030.00316.81
8.0.130.0000.00513.28
8.0.120.0000.00716.87
8.0.110.0030.00516.95
8.0.100.0030.00516.67
8.0.90.0070.00016.83
8.0.80.0090.01016.91
8.0.70.0040.00416.79
8.0.60.0000.00716.86
8.0.50.0040.00416.95
8.0.30.0090.00917.11
8.0.20.0090.01017.41
8.0.10.0040.00417.04
8.0.00.0120.00916.88
7.4.330.0000.00615.55
7.4.320.0000.00716.61
7.4.300.0030.00316.50
7.4.290.0000.00716.59
7.4.280.0000.00816.48
7.4.270.0050.00316.46
7.4.260.0000.00716.59
7.4.250.0030.00316.57
7.4.240.0000.00716.36
7.4.230.0040.00416.59
7.4.220.0030.00516.63
7.4.210.0030.01016.54
7.4.200.0000.00716.59
7.4.160.0080.01116.52
7.4.140.0090.01117.86
7.4.130.0100.00616.60
7.4.120.0090.01016.47
7.4.110.0130.00716.46
7.4.100.0090.01516.59
7.4.90.0080.00916.47
7.4.80.0150.00819.39
7.4.70.0120.00416.61
7.4.60.0100.00716.55
7.4.50.0070.01016.46
7.4.40.0080.00816.64
7.4.10.0060.01214.91
7.4.00.0110.00514.90
7.3.330.0030.00313.06
7.3.320.0050.00013.08
7.3.310.0030.00316.18
7.3.300.0030.00316.22
7.3.290.0080.00916.34
7.3.280.0090.00716.32
7.3.260.0120.01016.42
7.3.240.0110.00816.36
7.3.230.0070.01016.44
7.3.210.0060.01216.46
7.3.200.0030.01216.48
7.3.190.0060.01016.31
7.3.180.0060.00916.57
7.3.170.0120.00616.39
7.3.160.0070.01016.42
7.3.130.0070.01014.91
7.3.120.0040.01514.87
7.3.110.0100.01014.97
7.3.100.0120.00314.89
7.3.90.0000.01414.75
7.3.80.0100.00315.02
7.3.70.0080.00814.84
7.3.60.0030.01014.88
7.3.50.0070.00715.07
7.3.40.0090.00314.93
7.3.30.0070.01014.82
7.3.20.0070.00716.46
7.3.10.0120.00316.79
7.3.00.0080.00616.78
7.2.330.0120.00616.76
7.2.320.0150.01116.66
7.2.310.0140.00316.52
7.2.300.0120.01216.79
7.2.290.0070.01716.68
7.2.260.0090.00914.83
7.2.250.0070.01115.25
7.2.240.0090.00915.22
7.2.230.0030.01315.12
7.2.220.0030.01015.07
7.2.210.0070.00715.13
7.2.200.0090.00015.11
7.2.190.0030.00714.86
7.2.180.0060.00914.98
7.2.170.0070.01015.11
7.2.160.0000.01814.98
7.2.150.0070.00716.79
7.2.140.0060.00616.96
7.2.130.0050.01117.09
7.2.120.0070.00717.05
7.2.110.0100.00316.86
7.2.100.0070.01016.89
7.2.90.0090.00416.90
7.2.80.0060.01016.83
7.2.70.0080.00716.97
7.2.60.0060.00917.00
7.2.50.0020.00816.90
7.2.40.0070.00717.06
7.2.30.0070.00917.28
7.2.20.0080.00817.34
7.2.10.0060.01217.32
7.2.00.0080.01017.43
7.1.330.0070.00715.70
7.1.320.0110.00415.81
7.1.310.0030.01015.96
7.1.300.0070.00715.57
7.1.290.0060.00315.98
7.1.280.0030.01315.87
7.1.270.0060.00615.96
7.1.260.0070.00415.86
7.1.250.0020.01315.88
7.1.240.0040.01115.94
7.1.230.0040.01115.68
7.1.220.0030.01015.66
7.1.210.0040.00815.78
7.1.200.0090.00815.85
7.1.190.0100.00715.87
7.1.180.0030.00715.80
7.1.170.0030.01015.65
7.1.160.0030.01015.86
7.1.150.0090.00916.39
7.1.140.0070.01116.31
7.1.130.0100.00916.15
7.1.120.0050.01216.44
7.1.110.0080.00916.07
7.1.100.0120.00716.04
7.1.90.0110.01015.93
7.1.80.0110.00916.12
7.1.70.0500.01115.52
7.1.60.0130.01024.66
7.1.50.0120.01224.28
7.1.40.0150.01124.31
7.1.30.0200.01124.25
7.1.20.0170.01324.35
7.1.10.0060.01115.17
7.1.00.0090.00615.41
7.0.330.0070.00715.45
7.0.320.0080.00415.25
7.0.310.0000.01415.59
7.0.300.0070.00715.28
7.0.290.0030.00615.21
7.0.280.0060.00615.01
7.0.270.0050.00515.54
7.0.260.0040.00715.31
7.0.250.0060.00615.52
7.0.240.0040.00815.50
7.0.230.0080.00815.50
7.0.220.0040.00815.25
7.0.210.0030.01015.48
7.0.200.0060.00615.31
7.0.190.0000.01315.48
7.0.180.0130.00315.49
7.0.170.0030.00915.24
7.0.160.0070.00615.44
7.0.150.0040.00415.52
7.0.140.0090.00315.48
7.0.130.0060.00915.54
7.0.120.0070.00715.14
7.0.110.0030.00715.56
7.0.100.0070.00715.57
7.0.90.0000.01315.36
7.0.80.0000.01415.44
7.0.70.0000.00815.39
7.0.60.0040.00415.42
7.0.50.0000.01715.44
7.0.40.0040.01113.33
7.0.30.0080.00413.54
7.0.20.0030.01313.38
7.0.10.0000.01413.46
7.0.00.0100.00613.31
5.6.400.0060.00914.08
5.6.390.0120.00314.07
5.6.380.0070.01014.64
5.6.370.0060.00914.29
5.6.360.0100.00314.44
5.6.350.0000.01114.70
5.6.340.0040.00714.54
5.6.330.0030.01314.56
5.6.320.0100.00314.37
5.6.310.0030.01314.41
5.6.300.0030.01014.08
5.6.290.0020.01214.38
5.6.280.0030.00714.14
5.6.270.0090.00614.41
5.6.260.0070.01014.63
5.6.250.0040.00814.27
5.6.240.0070.00714.16
5.6.230.0070.00714.26
5.6.220.0070.00714.13
5.6.210.0030.01014.27
5.6.200.0030.01014.34
5.6.190.0040.01114.29
5.6.180.0090.00314.29
5.6.170.0030.01314.26
5.6.160.0030.01014.22
5.6.150.0070.01014.61
5.6.140.0100.00314.41
5.6.130.0060.00614.32
5.6.120.0070.00714.45
5.6.110.0040.00714.24
5.6.100.0120.00314.57
5.6.90.0090.00314.46
5.6.80.0060.00614.61
5.6.70.0060.01014.35
5.6.60.0080.00814.21
5.6.50.0000.01514.30
5.6.40.0030.01114.49
5.6.30.0120.00414.25
5.6.20.0030.00614.05
5.6.10.0060.00614.31
5.6.00.0000.00814.32

preferences:
25.88 ms | 403 KiB | 5 Q