3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); $values = ['true', false]; $needle = true; $inArray = array_reduce($values, function ($inArray, $value) use ($needle) { return $inArray || $value === $needle; }); var_dump(in_array(true, ['true', false])); var_dump($inArray);

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.0120.00318.30
8.3.50.0070.01017.98
8.3.40.0040.01218.65
8.3.30.0120.00318.59
8.3.20.0040.00420.34
8.3.10.0050.00323.52
8.3.00.0040.00419.26
8.2.180.0040.01818.18
8.2.170.0070.00722.96
8.2.160.0100.00720.57
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0080.00022.12
8.2.120.0030.00526.35
8.2.110.0070.00321.12
8.2.100.0060.00617.66
8.2.90.0000.00819.05
8.2.80.0050.00317.97
8.2.70.0040.00417.38
8.2.60.0000.00818.00
8.2.50.0040.00418.13
8.2.40.0040.00420.59
8.2.30.0050.00219.36
8.2.20.0040.00418.11
8.2.10.0000.00718.20
8.2.00.0070.00018.31
8.1.280.0090.00625.92
8.1.270.0040.00420.32
8.1.260.0110.00726.35
8.1.250.0050.00328.09
8.1.240.0060.00322.73
8.1.230.0080.00417.64
8.1.220.0060.00317.78
8.1.210.0030.00618.77
8.1.200.0080.00317.48
8.1.190.0080.00017.35
8.1.180.0040.00418.10
8.1.170.0060.00318.58
8.1.160.0070.00018.73
8.1.150.0000.00718.85
8.1.140.0040.00417.73
8.1.130.0030.00518.81
8.1.120.0000.00717.36
8.1.110.0030.00717.48
8.1.100.0000.00817.46
8.1.90.0000.00717.52
8.1.80.0040.00417.52
8.1.70.0040.00417.36
8.1.60.0050.00317.64
8.1.50.0030.00617.41
8.1.40.0030.00617.57
8.1.30.0030.00517.60
8.1.20.0000.00717.61
8.1.10.0000.00817.52
8.1.00.0000.00817.34
8.0.300.0090.00018.77
8.0.290.0060.00316.75
8.0.280.0000.00718.46
8.0.270.0030.00317.25
8.0.260.0060.00018.93
8.0.250.0000.00716.91
8.0.240.0080.00017.01
8.0.230.0000.00816.99
8.0.220.0030.00616.78
8.0.210.0030.00516.86
8.0.200.0000.00616.95
8.0.190.0080.00016.83
8.0.180.0000.00716.82
8.0.170.0050.00516.93
8.0.160.0000.00716.80
8.0.150.0040.00416.83
8.0.140.0040.00416.73
8.0.130.0030.00313.39
8.0.120.0040.00416.73
8.0.110.0070.00016.81
8.0.100.0040.00416.86
8.0.90.0000.00716.67
8.0.80.0130.00316.93
8.0.70.0000.00716.72
8.0.60.0000.00716.84
8.0.50.0040.00416.85
8.0.30.0120.00617.04
8.0.20.0090.01217.40
8.0.10.0000.00816.86
8.0.00.0050.01216.76
7.4.330.0050.00015.55
7.4.320.0070.00016.53
7.4.300.0030.00316.39
7.4.290.0030.00316.50
7.4.280.0040.00716.50
7.4.270.0110.00016.52
7.4.260.0030.00616.53
7.4.250.0040.00416.47
7.4.240.0020.00516.52
7.4.230.0030.00316.58
7.4.220.0000.00716.67
7.4.210.0040.01116.70
7.4.200.0000.00716.36
7.4.160.0100.00616.60
7.4.150.0030.01417.40
7.4.140.0140.00917.86
7.4.130.0110.01016.64
7.4.120.0090.01116.51
7.4.110.0070.01016.54
7.4.100.0150.00616.37
7.4.90.0100.00716.50
7.4.80.0060.01119.39
7.4.70.0130.01016.46
7.4.60.0110.00616.45
7.4.50.0050.00716.53
7.4.40.0080.00816.32
7.4.00.0070.01015.00
7.3.330.0060.00013.35
7.3.320.0000.00513.31
7.3.310.0030.00316.24
7.3.300.0030.00316.28
7.3.290.0100.00616.34
7.3.280.0080.00816.34
7.3.270.0130.00617.40
7.3.260.0080.01016.45
7.3.250.0120.00716.46
7.3.240.0090.01016.39
7.3.230.0170.00016.37
7.3.210.0100.00716.31
7.3.200.0070.01016.31
7.3.190.0070.01316.32
7.3.180.0100.00716.55
7.3.170.0060.01016.52
7.3.160.0120.00616.57
7.3.120.0100.01015.16
7.3.110.0070.01115.07
7.3.100.0060.00615.00
7.3.90.0070.00714.89
7.3.80.0060.00614.64
7.3.70.0130.00014.82
7.3.60.0060.00814.99
7.3.50.0070.00714.59
7.3.40.0060.01214.73
7.3.30.0060.00914.74
7.3.20.0000.01716.83
7.3.10.0040.00816.77
7.3.00.0030.01016.55
7.2.330.0080.01116.77
7.2.320.0080.00816.55
7.2.310.0030.01316.54
7.2.300.0060.00916.78
7.2.290.0120.00316.50
7.2.250.0120.00314.78
7.2.240.0040.01214.94
7.2.230.0100.00714.79
7.2.220.0070.00315.05
7.2.210.0030.00915.17
7.2.200.0130.00015.16
7.2.190.0030.01015.16
7.2.180.0070.00415.16
7.2.170.0060.00914.75
7.2.60.0040.00816.76
7.2.10.0700.00317.68
7.2.00.0360.00817.55
7.1.330.0070.00715.71
7.1.320.0060.00315.99
7.1.310.0060.00615.60
7.1.300.0120.00015.61
7.1.290.0000.01315.87
7.1.280.0000.01715.67
7.1.270.0090.00615.77
7.1.260.0060.00615.60
7.1.200.0170.00915.28
7.1.130.0340.00716.40
7.1.120.0280.01216.52
7.1.110.0280.01016.04
7.1.100.0250.01115.91
7.1.90.0460.00616.31
7.1.80.0460.00316.43
7.1.70.0420.01015.16
7.1.60.0550.01033.10
7.1.50.0580.00732.65
7.1.40.0500.01232.72
7.1.30.0620.01932.49
7.1.20.0490.01332.79
7.1.10.0620.00614.68
7.1.00.0330.01014.77

preferences:
32.98 ms | 400 KiB | 5 Q