3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = ['a','b',0,'c',1,2,'ee',3,4,5,'t','x','w']; $numbers = array_filter($array, 'is_numeric'); var_export($numbers); var_export(array_diff_key($array, $numbers));

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.4.120.0140.00524.21
8.4.110.0130.00818.82
8.4.100.0050.00419.00
8.4.90.0050.00420.71
8.4.80.0050.00318.63
8.4.70.0100.01117.75
8.4.60.0110.01118.78
8.4.50.0060.00318.60
8.4.40.0050.00319.24
8.4.30.0030.00720.44
8.4.20.0000.00919.61
8.4.10.0120.00322.17
8.3.250.0100.00918.63
8.3.240.0090.01116.97
8.3.230.0150.00416.26
8.3.220.0040.00518.90
8.3.210.0030.00518.29
8.3.200.0060.00316.57
8.3.190.0110.01116.85
8.3.180.0140.00717.02
8.3.170.0000.01420.53
8.3.160.0070.01117.29
8.3.150.0090.00917.35
8.3.140.0000.00816.39
8.3.130.0060.00916.68
8.3.120.0110.00018.77
8.3.110.0070.00320.94
8.3.100.0030.00516.74
8.3.90.0080.00026.77
8.3.80.0050.00516.38
8.3.70.0140.00716.58
8.3.60.0090.00616.38
8.3.50.0100.00720.15
8.3.40.0110.00318.67
8.3.30.0140.00419.04
8.3.20.0070.00724.18
8.3.10.0000.00824.66
8.3.00.0080.00026.16
8.2.290.0050.00520.34
8.2.280.0060.01218.14
8.2.270.0120.00617.21
8.2.260.0100.00716.48
8.2.250.0070.00718.29
8.2.240.0070.01117.15
8.2.230.0160.00022.58
8.2.220.0060.00924.06
8.2.210.0180.00026.77
8.2.200.0000.00816.50
8.2.190.0120.00316.58
8.2.180.0130.00325.92
8.2.170.0120.00318.79
8.2.160.0100.00322.96
8.2.150.0040.00425.66
8.2.140.0070.00024.66
8.2.130.0040.00426.16
8.2.120.0040.00426.16
8.2.110.0060.00322.24
8.2.100.0070.00417.66
8.2.90.0050.00319.13
8.2.80.0050.00319.38
8.2.70.0040.00417.50
8.2.60.0000.00817.90
8.2.50.0090.00018.07
8.2.40.0020.00518.09
8.2.30.0090.00018.11
8.2.20.0040.00420.46
8.2.10.0040.00418.06
8.2.00.0060.00319.14
8.1.330.0130.00921.86
8.1.320.0090.01116.21
8.1.310.0150.00316.82
8.1.300.0080.00020.22
8.1.290.0030.00630.84
8.1.280.0100.01425.92
8.1.270.0040.00423.99
8.1.260.0080.00026.35
8.1.250.0090.00028.09
8.1.240.0120.00020.64
8.1.230.0070.00420.85
8.1.220.0040.00418.77
8.1.210.0000.00918.77
8.1.200.0060.00317.36
8.1.190.0080.00017.23
8.1.180.0060.00318.10
8.1.170.0030.00518.46
8.1.160.0040.00418.70
8.1.150.0000.00718.58
8.1.140.0050.00217.47
8.1.130.0000.00817.37
8.1.120.0000.00717.39
8.1.110.0050.00317.41
8.1.100.0000.00817.29
8.1.90.0000.00717.36
8.1.80.0040.00417.41
8.1.70.0000.00817.36
8.1.60.0070.00317.48
8.1.50.0260.00417.40
8.1.40.0240.00417.40
8.1.30.0220.00517.54
8.1.20.0250.00317.48
8.1.10.0270.00017.42
8.1.00.0260.00317.25
8.0.300.0070.00319.90
8.0.290.0050.00317.04
8.0.280.0000.00818.45
8.0.270.0000.00716.66
8.0.260.0000.00716.79
8.0.250.0040.00416.93
8.0.240.0000.00716.76
8.0.230.0030.00316.89
8.0.220.0040.00416.81
8.0.210.0070.00016.83
8.0.200.0070.00016.77
8.0.190.0080.01216.80
8.0.180.0140.00616.72
8.0.170.0160.00616.86
8.0.160.0160.00016.80
8.0.150.0180.00016.62
8.0.140.0070.01116.66
8.0.130.0170.00016.78
8.0.120.0080.00516.71
8.0.110.0130.00316.64
8.0.100.0120.00816.75
8.0.90.0000.01116.71
8.0.80.0170.00316.70
8.0.70.0110.00516.83
8.0.60.0130.00216.79
8.0.50.0120.00616.85
8.0.30.0140.01216.78
8.0.20.0140.00816.70
8.0.10.0150.00616.88
7.4.330.0000.00515.55
7.4.320.0030.00316.39
7.4.300.0060.00016.54
7.4.290.0230.00616.34
7.4.280.0230.00316.42
7.4.270.0130.00716.45
7.4.260.0140.00916.53
7.4.250.0140.00616.41
7.4.240.0230.00316.49
7.4.230.0110.00816.31
7.4.220.0110.00716.32
7.4.210.0150.00716.48
7.4.200.0180.00016.44
7.4.190.0190.00016.50
7.4.180.0090.00916.58
7.4.160.0160.00316.47
7.4.150.0150.00416.45
7.4.140.0170.00016.44
7.4.130.0170.00616.38
7.4.120.0160.00416.40
7.4.110.0160.00616.32
7.4.100.0230.00016.45
7.4.90.0170.00516.46
7.4.80.0130.00816.33
7.4.70.0190.00316.32
7.4.60.0160.00416.15
7.4.50.0110.00516.26
7.4.40.0150.00516.26
7.4.30.0170.00416.31
7.4.20.0190.00016.30
7.4.10.0170.00416.24
7.4.00.0160.00516.27

preferences:
29.19 ms | 403 KiB | 5 Q