3v4l.org

run code in 300+ PHP versions simultaneously
<?php $order_ids = array(8,9,10,4,7); $arr = [ [4, 23, 1], [9, 66, 4], [8, 17, 3], ]; foreach($order_ids as $id) { foreach($arr as $record) { if($record[0] == $id) { $newArr[] = $record; break; } } } print_r($newArr);

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.60.0110.00718.31
8.3.50.0100.00316.42
8.3.40.0140.00718.71
8.3.30.0120.00318.70
8.3.20.0070.00024.18
8.3.10.0040.00424.66
8.3.00.0050.00326.16
8.2.180.0040.01125.92
8.2.170.0120.00419.13
8.2.160.0030.01022.96
8.2.150.0070.00025.66
8.2.140.0070.00024.66
8.2.130.0040.00426.16
8.2.120.0040.00420.07
8.2.110.0090.00020.77
8.2.100.0060.00617.78
8.2.90.0040.00419.10
8.2.80.0060.00317.97
8.2.70.0000.00817.63
8.2.60.0000.00818.05
8.2.50.0060.00318.07
8.2.40.0000.00818.34
8.2.30.0050.00318.20
8.2.20.0000.00818.15
8.2.10.0030.00619.29
8.2.00.0000.00819.26
8.1.280.0070.00725.92
8.1.270.0070.00023.99
8.1.260.0040.00428.09
8.1.250.0090.00028.09
8.1.240.0030.01221.00
8.1.230.0040.00717.64
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0040.00417.35
8.1.190.0000.00817.10
8.1.180.0040.00418.10
8.1.170.0060.00318.57
8.1.160.0040.00418.89
8.1.150.0030.00618.90
8.1.140.0080.00018.94
8.1.130.0000.00820.19
8.1.120.0040.00417.37
8.1.110.0000.00717.46
8.1.100.0030.00517.32
8.1.90.0030.00317.36
8.1.80.0020.00517.38
8.1.70.0030.00717.53
8.1.60.0050.00317.59
8.1.50.0030.00517.49
8.1.40.0040.00417.50
8.1.30.0030.00517.68
8.1.20.0040.00417.66
8.1.10.0000.00817.46
8.1.00.0040.00417.31
8.0.300.0070.00018.77
8.0.290.0050.00516.75
8.0.280.0030.00318.45
8.0.270.0040.00418.05
8.0.260.0000.00618.48
8.0.250.0050.00216.92
8.0.240.0070.00416.85
8.0.230.0040.00416.84
8.0.220.0030.00316.85
8.0.210.0030.00316.83
8.0.200.0080.00016.88
8.0.190.0060.00316.99
8.0.180.0000.00716.87
8.0.170.0040.00416.81
8.0.160.0000.00716.91
8.0.150.0070.00016.88
8.0.140.0080.00316.83
8.0.130.0060.00013.31
8.0.120.0000.00816.76
8.0.110.0050.00216.95
8.0.100.0040.00416.68
8.0.90.0000.00716.77
8.0.80.0120.00516.91
8.0.70.0040.00416.75
8.0.60.0040.00416.70
8.0.50.0040.00416.85
8.0.30.0070.01316.86
8.0.20.0090.00616.99
8.0.10.0070.00717.01
8.0.00.0060.01117.04
7.4.330.0040.00015.55
7.4.320.0060.00016.58
7.4.300.0000.00616.42
7.4.290.0070.00016.57
7.4.280.0030.00416.61
7.4.270.0060.00316.61
7.4.260.0000.00513.20
7.4.250.0030.00316.61
7.4.240.0070.00016.60
7.4.230.0000.00716.53
7.4.220.0020.00516.43
7.4.210.0000.01416.63
7.4.200.0050.00216.50
7.4.160.0080.00716.77
7.4.150.0100.00416.45
7.4.140.0100.00316.41
7.4.130.0110.00416.55
7.4.120.0090.00616.35
7.4.110.0100.01016.43
7.4.100.0090.00616.49
7.4.90.0110.00416.33
7.4.80.0100.00316.44
7.4.70.0010.01716.29
7.4.60.0200.00016.32
7.4.50.0060.00916.30
7.4.40.0130.00616.34
7.4.30.0040.01116.64
7.4.20.0070.00716.39
7.4.10.0080.00816.44
7.4.00.0130.00716.59
7.3.330.0040.00416.42
7.3.320.0000.00513.06
7.3.310.0040.00416.41
7.3.300.0030.00316.16
7.3.290.0100.00716.26
7.3.280.0040.01116.21
7.3.270.0070.00716.24
7.3.260.0090.00616.29
7.3.250.0100.00616.23
7.3.240.0120.00316.28
7.3.230.0030.01016.28
7.3.220.0070.00716.21
7.3.210.0070.01116.24
7.3.200.0060.01316.26
7.3.190.0140.00716.26
7.3.180.0070.00716.31
7.3.170.0070.00716.25
7.3.160.0090.00916.25
7.3.150.0000.01416.27
7.3.140.0070.00716.29
7.3.130.0060.00916.30
7.3.120.0090.01216.15
7.3.110.0060.01316.23
7.3.100.0130.00716.15
7.3.90.0000.01416.42
7.3.80.0090.00916.15
7.3.70.0080.01216.38
7.3.60.0110.01116.42
7.3.50.0070.01116.47
7.3.40.0060.01516.38
7.3.30.0140.00916.38
7.3.20.0100.00716.43
7.3.10.0070.01416.36
7.3.00.0100.01016.32

preferences:
26.39 ms | 400 KiB | 5 Q