3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tests = array( "42", 1337, 0x539, 02471, 0b10100111001, 1337e0, "not numeric", array(), 9.1, null ); foreach ($tests as $element) { if (\is_numeric($element)) { $int = (int) $element; echo var_export($int, true) . " is numeric", PHP_EOL; $float = (float) $element; echo var_export($float, true) . " is numeric", PHP_EOL; } else { echo var_export($element, true) . " is NOT numeric", PHP_EOL; } }

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.0070.00718.31
8.3.50.0060.01217.94
8.3.40.0080.01218.67
8.3.30.0080.00818.62
8.3.20.0090.00019.16
8.3.10.0080.00023.61
8.3.00.0000.00920.75
8.2.180.0150.00318.34
8.2.170.0110.00722.96
8.2.160.0070.00721.00
8.2.150.0000.00724.18
8.2.140.0050.00324.66
8.2.130.0050.00319.82
8.2.120.0050.00326.35
8.2.110.0070.00321.06
8.2.100.0080.00417.78
8.2.90.0060.00317.50
8.2.80.0030.00617.97
8.2.70.0030.00517.93
8.2.60.0050.00317.99
8.2.50.0040.00418.10
8.2.40.0030.00619.48
8.2.30.0050.00319.25
8.2.20.0050.00217.93
8.2.10.0040.00418.16
8.2.00.0030.00617.70
8.1.280.0190.00025.92
8.1.270.0030.00618.88
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0090.00022.46
8.1.230.0030.00722.12
8.1.220.0050.00317.78
8.1.210.0080.00018.77
8.1.200.0000.01117.35
8.1.190.0000.00817.22
8.1.180.0000.00718.10
8.1.170.0040.00418.26
8.1.160.0070.00018.88
8.1.150.0040.00418.83
8.1.140.0000.00717.45
8.1.130.0060.00620.14
8.1.120.0030.00317.41
8.1.110.0040.00417.38
8.1.100.0000.00717.43
8.1.90.0060.00317.42
8.1.80.0000.00717.50
8.1.70.0000.00717.48
8.1.60.0050.00317.57
8.1.50.0040.00417.40
8.1.40.0040.00417.51
8.1.30.0050.00217.55
8.1.20.0000.00817.55
8.1.10.0000.00817.41
8.1.00.0000.00717.46
8.0.300.0040.00418.77
8.0.290.0040.00416.58
8.0.280.0030.00318.40
8.0.270.0000.00817.27
8.0.260.0030.00318.36
8.0.250.0030.00516.80
8.0.240.0070.00016.83
8.0.230.0040.00416.88
8.0.220.0030.00616.82
8.0.210.0030.00316.91
8.0.200.0030.00316.84
8.0.190.0000.00716.88
8.0.180.0040.00416.81
8.0.170.0050.00316.92
8.0.160.0040.00416.97
8.0.150.0000.01016.78
8.0.140.0040.00416.91
8.0.130.0050.00013.29
8.0.120.0000.00716.79
8.0.110.0050.00316.91
8.0.100.0070.00016.91
8.0.90.0070.00016.83
8.0.80.0100.00516.80
8.0.70.0050.00216.92
8.0.60.0040.00416.89
8.0.50.0050.00216.82
8.0.30.0110.00717.02
8.0.20.0140.01017.40
8.0.10.0040.00416.99
8.0.00.0120.01116.84
7.4.330.0050.00015.55
7.4.320.0030.00316.59
7.4.300.0030.00316.49
7.4.290.0030.00316.51
7.4.280.0090.00016.59
7.4.270.0030.00316.40
7.4.260.0030.00316.56
7.4.250.0040.00416.58
7.4.240.0000.00716.59
7.4.230.0030.00316.41
7.4.220.0000.00816.35
7.4.210.0070.00816.50
7.4.200.0080.00016.49
7.4.160.0070.01016.55
7.4.140.0060.01417.86
7.4.130.0190.00316.54
7.4.120.0100.00716.56
7.4.110.0130.01016.37
7.4.100.0070.01016.62
7.4.90.0120.00616.41
7.4.80.0070.01019.39
7.4.70.0140.00516.46
7.4.60.0100.00616.36
7.4.50.0040.01116.60
7.4.40.0050.01116.35
7.4.00.0060.00614.89
7.3.330.0060.00013.00
7.3.320.0000.00613.12
7.3.310.0000.00916.26
7.3.300.0040.00416.18
7.3.290.0000.00716.27
7.3.280.0060.01016.26
7.3.260.0110.01016.57
7.3.240.0100.00816.43
7.3.230.0030.01316.25
7.3.210.0110.00616.54
7.3.200.0120.00916.56
7.3.190.0120.00916.46
7.3.180.0070.01416.21
7.3.170.0100.01116.22
7.3.160.0030.01416.26
7.3.10.0070.01016.73
7.3.00.0090.00616.55
7.2.330.0070.01016.27
7.2.320.0070.01716.66
7.2.310.0100.00616.65
7.2.300.0000.01816.43
7.2.290.0140.00316.73
7.2.130.0070.00717.05
7.2.120.0090.00316.88
7.2.110.0410.00815.42
7.2.100.0390.01015.83
7.2.90.0380.00615.76
7.2.80.0350.00315.77
7.2.70.0330.00815.79
7.2.60.0360.00616.04
7.2.50.0290.00915.66
7.2.40.0410.01115.78
7.2.30.0290.00815.77
7.2.20.0390.00615.89
7.2.10.0490.01015.92
7.2.00.0500.00915.97
7.1.250.0040.01115.82
7.1.230.0550.00813.74
7.1.220.1170.00613.88
7.1.210.0500.01213.68
7.1.200.0630.00613.93
7.1.190.0560.00913.57
7.1.180.0650.00013.72
7.1.170.0460.01013.76
7.1.160.0800.00913.73
7.1.150.0790.00713.90
7.1.140.0820.00313.58
7.1.130.0750.00913.79
7.1.120.0810.00913.75
7.1.110.1440.00713.51
7.1.100.0690.00913.79
7.1.90.0870.01013.63
7.1.80.1010.00313.82
7.1.70.0730.00613.38
7.1.60.1010.01032.00
7.1.50.1350.01031.77
7.1.40.1080.01031.70
7.1.30.1340.01331.71
7.1.20.1090.01231.72
7.1.10.0880.00313.45
7.1.00.0780.01613.61
5.6.380.0090.00714.38

preferences:
55.04 ms | 401 KiB | 5 Q