3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr0 = [ [ 'id' => 107, 'name' => 'Sarah', 'msgSinleer' => 2, 'subject' => [], ], [ 'id' => 110, 'name' => 'Manuela', 'msgSinleer' => 27, 'subject' => [], ], ]; $arr1 = [ [ 'id' => 110, 'Cliente' => 'Alexis', 'body' => 'Hola', 'fecha' => '06/01/2021 11:35 AM', 'status' => 1, 'tiempoSinLeer' => '15 01:00', ], [ 'id' => 110, 'Cliente' => 'Alexis', 'body' => 'Hola asd asdasd', 'fecha' => '05/26/2021 11:35 AM', 'status' => 1, 'tiempoSinLeer' => '21 01:00', ], [ 'id' => 107, 'Cliente' => 'George', 'body' => 'vhgfshsgf', 'fecha' => '06/15/2021 03:48 PM', 'status' => 1, 'tiempoSinLeer' => '1 08:48', ], ]; foreach($arr0 as $key => $record) { foreach($arr1 as $subject) { if($record['id'] === $subject['id']) $arr0[$key]['subject'][] = $subject; } } echo '<pre>'; print_r($arr0); echo '</pre>';

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.5.00.0140.00820.05
8.4.150.0020.00014.05
8.4.140.0150.00617.91
8.4.130.0110.01017.69
8.4.120.0050.00322.14
8.4.110.0150.00522.41
8.4.100.0130.00518.01
8.4.90.0110.01018.75
8.4.80.0120.00817.66
8.4.70.0070.00218.04
8.4.60.0040.00419.11
8.4.50.0020.00817.70
8.4.40.0060.01219.36
8.4.30.0080.00218.58
8.4.20.0120.00318.89
8.4.10.0040.01220.28
8.3.280.0090.00618.31
8.3.270.0110.00816.50
8.3.260.0120.00816.75
8.3.250.0120.00518.97
8.3.240.0120.00716.51
8.3.230.0100.00916.51
8.3.220.0080.00817.23
8.3.210.0090.00916.57
8.3.200.0050.00616.39
8.3.190.0060.01218.97
8.3.180.0080.01116.91
8.3.170.0180.00018.82
8.3.160.0090.01016.48
8.3.150.0080.00019.23
8.3.140.0000.00818.27
8.3.130.0080.00018.39
8.3.120.0040.01120.73
8.3.110.0050.00520.94
8.3.100.0040.00424.06
8.3.90.0040.00426.77
8.3.80.0000.00919.36
8.3.70.0130.01018.37
8.3.60.0110.00816.50
8.3.50.0120.00618.28
8.3.40.0120.00318.84
8.3.30.0140.00218.74
8.3.20.0070.00323.04
8.3.10.0060.00623.20
8.3.00.0030.00922.56
8.2.290.0100.00920.48
8.2.280.0090.00920.02
8.2.270.0100.01017.45
8.2.260.0080.00618.77
8.2.250.0150.00416.52
8.2.240.0160.00318.74
8.2.230.0060.00322.58
8.2.220.0030.00637.54
8.2.210.0050.00226.77
8.2.200.0090.00018.88
8.2.190.0000.01516.63
8.2.180.0070.01125.92
8.2.170.0070.01018.91
8.2.160.0080.00721.10
8.2.150.0090.00322.29
8.2.140.0080.00322.57
8.2.130.0090.00323.25
8.2.120.0050.00720.03
8.2.110.0050.00719.81
8.2.100.0100.00318.50
8.2.90.0110.00318.30
8.2.80.0070.00419.75
8.2.70.0090.00319.19
8.2.60.0050.00719.27
8.2.50.0030.00919.57
8.2.40.0080.00520.82
8.2.30.0090.00219.82
8.2.20.0070.00519.36
8.2.10.0080.00419.91
8.2.00.0060.00420.13
8.1.330.0100.00921.80
8.1.320.0130.00516.32
8.1.310.0170.00016.68
8.1.300.0090.00017.97
8.1.290.0040.00430.84
8.1.280.0070.01425.92
8.1.270.0050.00623.95
8.1.260.0110.00225.06
8.1.250.0100.00225.91
8.1.240.0090.00421.22
8.1.230.0040.01019.06
8.1.220.0080.00319.24
8.1.210.0060.00619.50
8.1.200.0130.00218.91
8.1.190.0050.00918.87
8.1.180.0080.00719.16
8.1.170.0100.00319.59
8.1.160.0050.00820.48
8.1.150.0060.00719.73
8.1.140.0060.00520.35
8.1.130.0030.00820.39
8.1.120.0030.00719.49
8.1.110.0070.00519.35
8.1.100.0090.00319.75
8.1.90.0050.00519.31
8.1.80.0050.00419.79
8.1.70.0050.00519.37
8.1.60.0060.00519.54
8.1.50.0030.00719.45
8.1.40.0040.00519.54
8.1.30.0040.00719.66
8.1.20.0080.00220.01
8.1.10.0070.00419.50
8.1.00.0040.00619.37
8.0.300.0050.00519.23
8.0.290.0090.00617.19
8.0.280.0060.00918.02
8.0.270.0040.00617.34
8.0.260.0080.00418.69
8.0.250.0090.00518.27
8.0.240.0090.00417.63
8.0.230.0080.00517.62
8.0.220.0030.00818.12
8.0.210.0100.00317.49
8.0.200.0060.00717.59
8.0.190.0070.00718.21
8.0.180.0070.00518.28
8.0.170.0090.00617.52
8.0.160.0070.00418.09
8.0.150.0060.00717.49
8.0.140.0100.00317.97
8.0.130.0080.00416.36
8.0.120.0090.00417.54
8.0.110.0120.00217.57
8.0.100.0080.00517.54
8.0.90.0100.00318.05
8.0.80.0090.00917.33
8.0.70.0060.00417.53
8.0.60.0100.00417.58
8.0.50.0080.00617.50
8.0.30.0100.00718.22
8.0.20.0090.00818.21
8.0.10.0120.00917.67
8.0.00.0120.00718.15
7.4.330.0090.00516.68
7.4.320.0140.00317.18
7.4.300.0110.00917.23
7.4.290.0170.00317.72
7.4.280.0150.00417.21
7.4.270.0140.00417.65
7.4.260.0130.00316.11
7.4.250.0110.00717.16
7.4.240.0100.00517.07
7.4.230.0160.00217.24
7.4.220.0120.00517.23
7.4.210.0130.00717.20
7.4.200.0160.00317.27
7.4.190.0170.00517.57
7.4.180.0200.00317.63
7.4.160.0250.00517.80
7.4.150.0160.00617.13
7.4.140.0180.00417.17
7.4.130.0190.00517.18
7.4.120.0160.00817.21
7.4.110.0230.00517.15
7.4.100.0170.00717.17
7.4.90.0200.00617.12
7.4.80.0180.00717.20
7.4.70.0160.00817.15
7.4.60.0180.00617.17
7.4.50.0180.00717.07
7.4.40.0140.00917.07
7.4.30.0120.01017.16
7.4.20.0180.00817.16
7.4.10.0180.00617.10
7.4.00.0170.00717.23
7.3.330.0130.00417.01
7.3.320.0110.00515.99
7.3.310.0120.00517.08
7.3.300.0090.00717.13
7.3.290.0120.00716.74
7.3.280.0200.00317.56
7.3.270.0140.00817.10
7.3.260.0170.00617.09
7.3.250.0160.00917.09
7.3.240.0190.00417.03
7.3.230.0150.00717.01
7.3.220.0160.00817.05
7.3.210.0180.00616.97
7.3.200.0230.00317.01
7.3.190.0190.00717.06
7.3.180.0150.00916.97
7.3.170.0190.00417.15
7.3.160.0150.00917.04
7.3.150.0210.00317.46
7.3.140.0160.00716.99
7.3.130.0170.00816.97
7.3.120.0210.00317.05
7.3.110.0150.00716.88
7.3.100.0190.00616.94
7.3.90.0160.00917.26
7.3.80.0140.00817.03
7.3.70.0160.00717.15
7.3.60.0160.00717.17
7.3.50.0210.00417.61
7.3.40.0180.00717.77
7.3.30.0190.00617.14
7.3.20.0160.00918.29
7.3.10.0180.00818.34
7.3.00.0220.00418.26

preferences:
32.02 ms | 403 KiB | 5 Q