3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr1 = [ "First" =>[ "Name" => "John", "Id" => 123 ], "Second" =>[ "Name" => "Peter", "Id" => 45 ] ]; $arr2 = [ "First" =>[ "Age" => 34, "Id" => 123 ], "Second" =>[ "Age" => 34, "Id" => 45 ] ]; print_r(array_replace_recursive($arr1, $arr2));

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.0000.00816.41
8.3.120.0030.00620.74
8.3.110.0080.00020.94
8.3.100.0000.00916.48
8.3.90.0000.00826.77
8.3.80.0060.00316.38
8.3.70.0120.00916.61
8.3.60.0150.00318.18
8.3.50.0070.00718.07
8.3.40.0140.00018.71
8.3.30.0090.00918.59
8.3.20.0050.00319.29
8.3.10.0030.00523.66
8.3.00.0070.00020.66
8.2.250.0040.00418.26
8.2.240.0040.00418.74
8.2.230.0060.00922.58
8.2.220.0080.00024.06
8.2.210.0060.00626.77
8.2.200.0090.00018.16
8.2.190.0160.00618.03
8.2.180.0110.01525.92
8.2.170.0040.01118.82
8.2.160.0000.01322.08
8.2.150.0100.00024.18
8.2.140.0030.00524.66
8.2.130.0070.00026.16
8.2.120.0080.00020.80
8.2.110.0070.00320.57
8.2.100.0070.00417.59
8.2.90.0040.00417.55
8.2.80.0030.00617.97
8.2.70.0030.00618.05
8.2.60.0040.00418.09
8.2.50.0000.00818.10
8.2.40.0000.00719.25
8.2.30.0000.00719.10
8.2.20.0040.00417.99
8.2.10.0080.00018.00
8.2.00.0030.00517.64
8.1.300.0040.00416.06
8.1.290.0030.00630.84
8.1.280.0140.00025.92
8.1.270.0100.00023.83
8.1.260.0030.00526.35
8.1.250.0070.00028.09
8.1.240.0040.00423.82
8.1.230.0040.00822.75
8.1.220.0030.00517.74
8.1.210.0030.00618.90
8.1.200.0090.00017.23
8.1.190.0050.00317.23
8.1.180.0050.00318.10
8.1.170.0030.00618.48
8.1.160.0070.00018.82
8.1.150.0040.00418.75
8.1.140.0040.00422.19
8.1.130.0040.00418.73
8.1.120.0000.00717.32
8.1.110.0040.00417.34
8.1.100.0040.00417.26
8.1.90.0000.00717.43
8.1.80.0060.00317.29
8.1.70.0000.00817.38
8.1.60.0000.00817.44
8.1.50.0040.00417.43
8.1.40.0040.00417.46
8.1.30.0050.00517.53
8.1.20.0040.00417.60
8.1.10.0000.00717.44
8.1.00.0050.00217.27
8.0.300.0040.00419.63
8.0.290.0000.00716.63
8.0.280.0070.00018.34
8.0.270.0030.00517.25
8.0.260.0000.00618.41
8.0.250.0030.00716.79
8.0.240.0000.00716.89
8.0.230.0030.00316.88
8.0.220.0000.00716.79
8.0.210.0070.00016.89
8.0.200.0000.00716.84
8.0.190.0120.00016.76
8.0.180.0000.00816.94
8.0.170.0030.00616.84
8.0.160.0040.00416.91
8.0.150.0070.00016.84
8.0.140.0040.00416.77
8.0.130.0030.00313.27
8.0.120.0000.00716.75
8.0.110.0080.00016.77
8.0.100.0030.00316.89
8.0.90.0070.00016.81
8.0.80.0090.00516.83
8.0.70.0040.00416.73
8.0.60.0040.00416.89
8.0.50.0050.00216.65
8.0.30.0060.01216.78
8.0.20.0140.01017.40
8.0.10.0040.00416.93
8.0.00.0170.00216.68
7.4.330.0000.00515.55
7.4.320.0000.00716.55
7.4.300.0000.00616.36
7.4.290.0030.00316.49
7.4.280.0030.00616.36
7.4.270.0070.00016.59
7.4.260.0000.00716.48
7.4.250.0000.00716.39
7.4.240.0000.00716.52
7.4.230.0040.00416.33
7.4.220.0000.00716.43
7.4.210.0070.00816.50
7.4.200.0000.00716.32
7.4.160.0100.00716.41
7.4.140.0070.01017.86
7.4.130.0180.00016.27
7.4.120.0110.00816.34
7.4.110.0130.00916.38
7.4.100.0130.00316.34
7.4.90.0090.00916.40
7.4.80.0060.01219.39
7.4.70.0120.00416.25
7.4.60.0190.00416.37
7.4.50.0110.00416.06
7.4.40.0060.01016.28
7.4.00.0040.01414.96
7.3.330.0020.00212.96
7.3.320.0000.00512.92
7.3.310.0030.00616.06
7.3.300.0030.00316.11
7.3.290.0000.00716.11
7.3.280.0110.00516.10
7.3.260.0120.00816.25
7.3.240.0120.00916.19
7.3.230.0080.00816.35
7.3.210.0060.01016.42
7.3.200.0070.01416.28
7.3.190.0140.00316.09
7.3.180.0000.01716.44
7.3.170.0030.01416.23
7.3.160.0130.00316.50
7.2.330.0130.00316.36
7.2.320.0100.00716.45
7.2.310.0060.01016.17
7.2.300.0080.01416.43
7.2.290.0030.01316.44
7.2.110.0060.00616.43
7.2.100.0060.00616.35
7.2.90.0080.00616.56
7.2.80.0060.01016.38
7.2.70.0050.00816.57
7.2.60.0050.01016.67
7.2.50.0090.00616.63
7.2.40.0040.01016.68
7.2.30.0090.00716.84
7.2.20.0060.01216.67
7.2.10.0080.00516.54
7.2.00.0060.00816.53
7.1.230.0090.00515.58
7.1.220.0040.01015.67
7.1.210.0060.00815.71
7.1.200.0120.00115.68
7.1.190.0030.01015.59
7.1.180.0090.00615.75
7.1.170.0070.00515.76
7.1.160.0080.00615.73
7.1.150.0030.00815.64
7.1.140.0070.00715.53
7.1.130.0080.00515.72
7.1.120.0070.00815.52
7.1.110.0090.00615.72
7.1.100.0100.00315.59
7.1.90.0070.00515.71
7.1.80.0100.00515.65
7.1.70.0100.00315.61
7.1.60.0220.01433.62
7.1.50.0260.00833.69
7.1.40.0230.01333.68
7.1.30.0250.01133.49
7.1.20.0180.01733.40
7.1.10.0120.00315.50
7.1.00.0090.00615.67
5.6.380.0110.00814.34

preferences:
15.15 ms | 403 KiB | 5 Q