3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ ['occurence' => 17, 'word' => 'sampleword'], ['occurence' => 14, 'word' => 'sampleword1'], ['occurence' => 14, 'word' => 'sampleword2'], ['occurence' => 14, 'word' => 'sampleword3'], ]; $forbidden_words = [ 'sampleword1', 'sampleword3' ]; var_export( array_udiff( $array, $forbidden_words, fn($a, $b) => ($a['word'] ?? $a) <=> ($b['word'] ?? $b) ) );

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.0040.00423.88
8.4.110.0040.00718.58
8.4.100.0110.00918.76
8.4.90.0050.00620.62
8.4.80.0040.00420.58
8.4.70.0120.00817.84
8.4.60.0080.00218.77
8.4.50.0070.00418.63
8.4.40.0030.00619.55
8.4.30.0090.00918.60
8.4.20.0060.01517.84
8.4.10.0100.01023.57
8.3.250.0100.00917.02
8.3.240.0120.00617.09
8.3.230.0120.00716.69
8.3.220.0030.00519.05
8.3.210.0110.00716.57
8.3.200.0030.00616.80
8.3.190.0120.00618.88
8.3.180.0100.00918.28
8.3.170.0070.01117.12
8.3.160.0100.01018.22
8.3.150.0110.00716.49
8.3.140.0040.00417.22
8.3.130.0120.00318.33
8.3.120.0000.00920.99
8.3.110.0060.00318.30
8.3.100.0110.00716.48
8.3.90.0090.00926.77
8.3.80.0070.00318.30
8.3.70.0070.01018.22
8.3.60.0200.00016.63
8.3.50.0120.00316.56
8.3.40.0030.01121.80
8.3.30.0070.00718.44
8.3.20.0050.00224.18
8.3.10.0040.00424.66
8.3.00.0040.00426.16
8.2.290.0040.00420.27
8.2.280.0150.00418.64
8.2.270.0090.01217.12
8.2.260.0130.00616.82
8.2.250.0000.00818.38
8.2.240.0050.00518.99
8.2.230.0000.00820.94
8.2.220.0130.00716.63
8.2.210.0100.01026.77
8.2.200.0060.00316.88
8.2.190.0110.01116.63
8.2.180.0160.00316.60
8.2.170.0110.00418.91
8.2.160.0100.00322.96
8.2.150.0040.00425.66
8.2.140.0000.00724.66
8.2.130.0040.00426.16
8.2.120.0040.00419.83
8.2.110.0030.00620.48
8.2.100.0070.00417.78
8.2.90.0030.00617.75
8.2.80.0060.00318.61
8.2.70.0000.00917.63
8.2.60.0000.00817.50
8.2.50.0050.00317.63
8.2.40.0050.00517.72
8.2.30.0170.00017.72
8.2.20.0120.00617.72
8.2.10.0130.00217.72
8.2.00.0150.00017.73
8.1.330.0090.00922.07
8.1.320.0110.00917.67
8.1.310.0100.00718.24
8.1.300.0030.00616.32
8.1.290.0000.01030.84
8.1.280.0110.00425.92
8.1.270.0030.01424.66
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0090.00621.99
8.1.230.0050.00520.84
8.1.220.0020.00518.60
8.1.210.0040.00418.77
8.1.200.0000.00817.36
8.1.190.0040.00417.35
8.1.180.0000.00918.10
8.1.170.0160.00017.72
8.1.160.0130.00317.72
8.1.150.0120.00417.72
8.1.140.0050.01017.72
8.1.130.0080.00817.72
8.1.120.0120.00417.72
8.1.110.0120.00417.72
8.1.100.0090.00717.72
8.1.90.0140.00717.72
8.1.80.0130.00417.72
8.1.70.0120.00417.72
8.1.60.0110.00617.72
8.1.50.0130.00317.72
8.1.40.0170.00017.72
8.1.30.0080.00817.72
8.1.20.0190.00017.72
8.1.10.0090.00917.72
8.1.00.0100.00717.72
8.0.300.0040.00418.77
8.0.290.0080.00016.75
8.0.280.0110.00717.72
8.0.270.0000.01817.72
8.0.260.0160.00017.72
8.0.250.0040.01217.72
8.0.240.0110.00517.72
8.0.230.0100.00717.72
8.0.220.0080.01017.72
8.0.210.0100.00717.72
8.0.200.0130.00417.72
8.0.190.0050.01117.72
8.0.180.0080.00817.72
8.0.170.0160.00017.72
8.0.160.0110.00417.72
8.0.150.0100.00717.72
8.0.140.0170.00017.72
8.0.130.0080.00817.72
8.0.120.0080.00817.72
8.0.110.0150.00017.72
8.0.100.0110.00517.72
8.0.90.0160.00017.72
8.0.80.0150.00017.72
8.0.70.0110.00617.72
8.0.60.0070.00917.72
8.0.50.0080.00817.72
8.0.30.0170.00017.72
8.0.20.0080.00817.72
8.0.10.0110.00417.72

preferences:
28.92 ms | 403 KiB | 5 Q