3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array( array( "contact_name" => "contact1", "email" => "", "id" => 1 ), array( "contact_name" => "contact2", "email" => null, "id" => 2 ), array( "contact_name" => "contact3", "email" => "user@domain.com", "id" => 3 ), ); $filtered = array_filter($array, function($contact) { if(!empty($contact['email']) && $contact['email'] != '') { return $contact; } }); echo '<pre><code>', print_r($filtered), '</code></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.3.60.0160.00618.55
8.3.50.0110.00717.97
8.3.40.0000.01618.77
8.3.30.0110.00418.71
8.3.20.0050.00318.77
8.3.10.0040.00421.79
8.3.00.0050.00221.94
8.2.180.0140.00318.15
8.2.170.0060.01222.96
8.2.160.0140.00019.11
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0060.00322.09
8.2.120.0080.00026.35
8.2.110.0030.00620.93
8.2.100.0060.01017.72
8.2.90.0000.00819.07
8.2.80.0060.00317.97
8.2.70.0000.00817.63
8.2.60.0090.00017.93
8.2.50.0060.00318.07
8.2.40.0080.00018.35
8.2.30.0000.00718.14
8.2.20.0000.00818.17
8.2.10.0000.00818.13
8.2.00.0080.00019.47
8.1.280.0120.00325.92
8.1.270.0000.00820.38
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0060.00319.13
8.1.230.0080.00418.88
8.1.220.0000.00817.79
8.1.210.0090.00018.77
8.1.200.0060.00317.36
8.1.190.0050.00317.35
8.1.180.0000.00818.10
8.1.170.0040.00418.82
8.1.160.0040.00418.81
8.1.150.0040.00418.93
8.1.140.0000.00718.83
8.1.130.0070.00319.99
8.1.120.0050.00317.46
8.1.110.0040.00417.45
8.1.100.0000.00817.50
8.1.90.0000.00717.35
8.1.80.0000.00817.38
8.1.70.0000.00917.48
8.1.60.0040.00417.62
8.1.50.0040.00417.42
8.1.40.0030.00517.51
8.1.30.0040.00417.57
8.1.20.0040.00417.60
8.1.10.0000.00717.65
8.1.00.0050.00317.39
8.0.300.0060.00318.77
8.0.290.0070.00016.63
8.0.280.0040.00418.40
8.0.270.0070.00016.73
8.0.260.0050.00218.36
8.0.250.0080.00016.94
8.0.240.0040.00417.00
8.0.230.0040.00416.92
8.0.220.0060.00316.94
8.0.210.0070.00016.80
8.0.200.0000.00716.82
8.0.190.0000.00716.92
8.0.180.0000.00716.87
8.0.170.0030.00616.80
8.0.160.0000.00816.89
8.0.150.0000.00816.83
8.0.140.0000.00716.84
8.0.130.0050.00013.38
8.0.120.0070.00016.96
8.0.110.0000.00716.91
8.0.100.0000.00817.01
8.0.90.0040.00416.79
8.0.80.0120.00416.92
8.0.70.0040.00416.80
8.0.60.0080.00016.93
8.0.50.0000.00716.77
8.0.30.0090.01117.13
8.0.20.0100.00917.40
8.0.10.0000.00716.99
8.0.00.0070.01116.83
7.4.330.0050.00015.55
7.4.320.0000.00716.62
7.4.300.0030.00316.42
7.4.290.0070.00016.43
7.4.280.0040.00416.40
7.4.270.0000.00716.42
7.4.260.0070.00016.61
7.4.250.0000.00816.42
7.4.240.0000.00816.48
7.4.230.0040.00416.45
7.4.220.0080.00016.61
7.4.210.0080.00816.61
7.4.200.0050.00216.70
7.4.160.0080.00816.57
7.4.140.0130.00717.86
7.4.130.0110.00716.50
7.4.120.0080.01216.49
7.4.110.0070.01516.48
7.4.100.0070.01416.58
7.4.90.0110.00716.42
7.4.80.0080.00819.39
7.4.70.0040.01216.49
7.4.60.0120.00616.50
7.4.50.0140.00416.58
7.4.40.0110.00516.42
7.4.00.0060.01014.96
7.3.330.0000.00513.32
7.3.320.0060.00013.34
7.3.310.0060.00016.18
7.3.300.0000.00616.37
7.3.290.0070.00016.19
7.3.280.0120.00316.32
7.3.260.0110.01016.47
7.3.240.0100.00816.43
7.3.230.0080.00816.31
7.3.210.0100.00716.50
7.3.200.0070.01016.40
7.3.190.0060.01616.27
7.3.180.0140.00716.36
7.3.170.0030.01416.28
7.3.160.0200.00016.37
7.3.120.0090.00814.85
7.3.110.0070.00814.63
7.3.100.0070.00814.93
7.3.90.0100.00714.86
7.3.80.0080.00614.91
7.3.70.0060.00614.84
7.3.60.0020.01014.68
7.3.50.0040.01214.72
7.3.40.0000.01414.69
7.3.30.0030.01214.61
7.3.20.0070.00716.65
7.3.10.0090.00316.61
7.3.00.0000.01016.79
7.2.330.0120.00616.40
7.2.320.0070.01016.85
7.2.310.0130.01116.66
7.2.300.0170.00016.48
7.2.290.0100.01016.42
7.2.250.0110.00714.95
7.2.240.0060.01115.02
7.2.230.0060.00914.91
7.2.220.0080.00815.01
7.2.210.0050.00914.97
7.2.200.0110.00315.01
7.2.190.0070.00514.95
7.2.180.0110.00515.00
7.2.170.0090.00814.96
7.2.160.0030.00615.00
7.2.150.0040.01116.73
7.2.140.0070.01016.85
7.2.130.0000.01116.69
7.2.120.0060.00917.06
7.2.110.0050.00816.99
7.2.100.0880.00815.91
7.2.90.0970.00915.92
7.2.80.1130.00815.86
7.2.70.0890.00515.95
7.2.60.0970.01015.99
7.2.50.1020.00815.99
7.2.40.0950.01015.91
7.2.30.1260.00715.91
7.2.20.1010.01015.87
7.2.10.1690.00916.09
7.2.00.1170.01016.02
7.1.330.0000.01515.88
7.1.320.0060.01015.92
7.1.310.0020.01015.90
7.1.300.0070.00515.81
7.1.290.0050.00915.75
7.1.280.0090.00215.68
7.1.270.0080.00415.77
7.1.260.0050.00915.80
7.1.250.0150.00015.61
7.1.240.0030.01015.78
7.1.230.0070.00415.69
7.1.220.0060.00615.63
7.1.210.0840.01614.79
7.1.200.0820.00814.85
7.1.190.1070.00714.79
7.1.180.0850.00914.70
7.1.170.1030.00814.89
7.1.160.0940.00514.69
7.1.150.1060.01114.79
7.1.140.1120.00214.82
7.1.130.1100.00714.72
7.1.120.1040.00314.72
7.1.110.1020.00814.72
7.1.100.1020.00714.66
7.1.90.1330.00814.82
7.1.80.1340.01014.70
7.1.70.1190.00914.78
7.1.60.1260.00823.73
7.1.50.1560.00623.80
7.1.40.1840.01123.68
7.1.30.1530.01323.75
7.1.20.1750.00723.87
7.1.10.1100.01014.67
7.1.00.1080.01314.73
7.0.330.0030.01015.34
7.0.320.0040.01115.41
7.0.310.0060.01015.33
7.0.300.0080.00815.33
7.0.290.0030.01215.49
7.0.280.0000.00915.42
7.0.270.0120.00615.41
7.0.260.0040.01114.95
7.0.250.0070.00715.30
7.0.240.0030.00915.53
7.0.230.0150.00015.49
7.0.220.0040.01115.18
7.0.210.0070.00415.38
7.0.200.0070.00715.52
7.0.190.0080.00815.12
7.0.180.0040.00415.50
7.0.170.0090.00315.41
7.0.160.0060.00915.23
7.0.150.0040.01115.43
7.0.140.0090.00615.43
7.0.130.0030.01015.53
7.0.120.0060.00715.45
7.0.110.0040.00715.51
7.0.100.0000.00915.46
7.0.90.0040.00715.50
7.0.80.0110.00315.38
7.0.70.0070.00715.45
7.0.60.0000.00815.31
7.0.50.0070.00715.48
7.0.40.0030.00513.61
7.0.30.0050.00313.19
7.0.20.0030.01013.47
7.0.10.0000.00913.34
7.0.00.0030.01013.26
5.6.400.0090.00614.32
5.6.390.0030.01314.45
5.6.380.0070.00414.59
5.6.370.0060.00914.63
5.6.360.0040.01114.34
5.6.350.0030.01414.59
5.6.340.0060.00714.57
5.6.330.0180.00014.52
5.6.320.0050.00814.54
5.6.310.0120.00314.45
5.6.300.0060.00914.41
5.6.290.0070.01014.60
5.6.280.0030.01314.38
5.6.270.0060.00614.36
5.6.260.0060.00614.54
5.6.250.0000.01014.38
5.6.240.0120.00414.50
5.6.230.0030.00714.15
5.6.220.0100.00014.17
5.6.210.0040.01114.20
5.6.200.0000.01214.30
5.6.190.0030.01214.46
5.6.180.0030.01014.47
5.6.170.0030.01014.16
5.6.160.0000.00914.23
5.6.150.0080.00514.33
5.6.140.0000.01414.38
5.6.130.0040.00814.47
5.6.120.0060.00914.20
5.6.110.0070.01014.23
5.6.100.0120.00314.54
5.6.90.0110.00613.99
5.6.80.0060.01214.04
5.6.70.0030.01214.21
5.6.60.0070.00714.34
5.6.50.0080.00814.64
5.6.40.0060.00314.16
5.6.30.0030.00614.23
5.6.20.0070.00714.44
5.6.10.0030.01014.62
5.6.00.0080.00314.19

preferences:
52.45 ms | 400 KiB | 5 Q