3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "Compare two numeric strings (same semantic 1): (NAN == 0) = " . (NAN == 0 ? 'true' : 'false') . "\n"; echo "Compare two numeric strings (same semantic 2): (NAN > 1 ) = " . (NAN > 0 ? 'true' : 'false') . "\n"; echo "Compare two numeric strings (same semantic 3): (NAN < 1) = " . (NAN < 0 ? 'true' : 'false') . "\n"; echo "Compare two numeric strings (same semantic 4): (NAN == -1) = " . (NAN == -1 ? 'true' : 'false') . "\n"; echo "Compare two numeric strings (same semantic 5): (NAN > -1) = " . (NAN > -1 ? 'true' : 'false') . "\n"; echo "Compare two numeric strings (same semantic 6): (NAN > -1) = " . (NAN > -1 ? 'true' : 'false') . "\n";

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.0080.00616.63
8.3.50.0080.00722.05
8.3.40.0160.00318.70
8.3.30.0070.01318.93
8.3.20.0070.00020.35
8.3.10.0090.00021.73
8.3.00.0040.00417.55
8.2.180.0110.00416.38
8.2.170.0130.00322.96
8.2.160.0130.00720.38
8.2.150.0090.00024.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0000.00721.02
8.2.110.0080.00022.08
8.2.100.0070.01018.03
8.2.90.0000.00819.07
8.2.80.0000.00817.97
8.2.70.0000.00817.50
8.2.60.0050.00317.80
8.2.50.0050.00318.07
8.2.40.0000.00819.88
8.2.30.0040.00418.29
8.2.20.0060.00317.74
8.2.10.0000.00717.87
8.2.00.0040.00417.55
8.1.280.0090.00625.92
8.1.270.0080.00023.98
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0040.00422.00
8.1.230.0100.00019.15
8.1.220.0030.00517.74
8.1.210.0030.00518.77
8.1.200.0030.00717.23
8.1.190.0030.00616.97
8.1.180.0000.00718.10
8.1.170.0040.00418.50
8.1.160.0040.00422.02
8.1.150.0000.01118.76
8.1.140.0030.00617.44
8.1.130.0000.00717.86
8.1.120.0030.00317.31
8.1.110.0040.00417.29
8.1.100.0040.00417.41
8.1.90.0000.00717.35
8.1.80.0000.00717.45
8.1.70.0030.00317.37
8.1.60.0060.00617.45
8.1.50.0000.00717.46
8.1.40.0000.00717.45
8.1.30.0000.00817.52
8.1.20.0040.00417.53
8.1.10.0040.00417.35
8.1.00.0040.00417.36
8.0.300.0000.00718.77
8.0.290.0090.00016.63
8.0.280.0000.00718.30
8.0.270.0070.00017.19
8.0.260.0000.00617.23
8.0.250.0000.00716.84
8.0.240.0030.00316.91
8.0.230.0000.00716.85
8.0.220.0030.00316.79
8.0.210.0040.00416.76
8.0.200.0040.00716.80
8.0.190.0070.00016.82
8.0.180.0000.00816.92
8.0.170.0030.00516.88
8.0.160.0030.00316.82
8.0.150.0030.00316.81
8.0.140.0000.00716.88
8.0.130.0000.00713.27
8.0.120.0080.00016.88
8.0.110.0000.00716.77
8.0.100.0000.00716.93
8.0.90.0030.00316.89
8.0.80.0100.00516.86
8.0.70.0030.00516.88
8.0.60.0040.00416.61
8.0.50.0000.00816.70
8.0.30.0090.00917.16
8.0.20.0070.01517.40
8.0.10.0050.00216.92
8.0.00.0120.00616.81
7.4.330.0000.00515.00
7.4.320.0020.00516.47
7.4.300.0040.00416.47
7.4.290.0070.00016.26
7.4.280.0040.00416.37
7.4.270.0000.00716.34
7.4.260.0000.00716.36
7.4.250.0040.00416.36
7.4.240.0030.00316.42
7.4.230.0030.00316.25
7.4.220.0130.00316.31
7.4.210.0030.01016.43
7.4.200.0070.00016.57
7.4.160.0060.00916.55
7.4.150.0120.00617.40
7.4.140.0150.00517.86
7.4.130.0080.00816.33
7.4.120.0100.01016.38
7.4.110.0110.00816.47
7.4.100.0100.00716.22
7.4.90.0090.01116.31
7.4.80.0130.00619.39
7.4.70.0060.01216.54
7.4.60.0070.01016.36
7.4.50.0040.00416.52
7.4.40.0030.01316.48
7.4.30.0110.00516.26
7.4.00.0160.00015.06
7.3.330.0000.00513.13
7.3.320.0030.00313.06
7.3.310.0070.00016.14
7.3.300.0050.00216.28
7.3.290.0110.00416.32
7.3.280.0090.01116.23
7.3.270.0110.00917.40
7.3.260.0150.00316.32
7.3.250.0120.00816.20
7.3.240.0100.00716.23
7.3.230.0090.00616.39
7.3.210.0150.00816.23
7.3.200.0100.00619.39
7.3.190.0120.00816.16
7.3.180.0060.01616.45
7.3.170.0130.00316.43
7.3.160.0100.00616.45
7.3.120.0000.01414.79
7.2.330.0120.00916.59
7.2.320.0090.00916.56
7.2.310.0060.01016.35
7.2.300.0120.00316.32
7.2.290.0030.01316.27
7.2.110.0230.00616.11
7.2.60.0090.00616.81
7.2.00.0000.01119.54
7.1.200.0050.00515.77
7.1.70.0030.00516.82
7.1.60.0000.01117.12
7.1.50.0220.01334.50
7.1.00.0070.07322.45
7.0.200.0040.00416.82
7.0.140.0030.07322.01
7.0.60.0070.07019.91
7.0.50.0100.07317.88
7.0.40.0170.08020.13
7.0.30.0170.04020.00
7.0.20.0330.08320.02
7.0.10.0030.08320.04
7.0.00.0070.08320.18
5.6.280.0030.07320.77
5.6.210.0000.08320.60
5.6.200.0030.05318.21
5.6.190.0000.04720.60
5.6.180.3900.04020.27
5.6.170.0330.07320.54
5.6.160.0000.08320.34
5.6.150.0070.08018.12
5.6.140.0100.07718.20
5.6.130.0000.04318.17
5.6.120.0030.04321.01
5.6.110.0130.08321.13
5.6.100.0130.07020.97
5.6.90.0030.07721.05
5.6.80.0070.07020.52
5.6.70.4370.04020.49
5.5.350.0130.06020.36
5.5.340.0030.08317.93
5.5.330.0100.08020.37
5.5.320.0330.05320.29
5.5.310.0300.07720.41
5.5.300.0070.04317.91
5.5.290.0030.06018.00
5.5.280.0070.04020.97
5.5.270.0100.07020.88
5.5.260.0130.08020.86
5.5.250.0170.07320.60
5.5.240.0070.03320.27
5.4.450.0570.06719.32
5.4.440.0230.05719.52
5.4.430.0130.05719.66
5.4.420.0230.07319.48
5.4.410.0130.05018.80
5.4.400.0370.05718.52
5.4.390.0330.05718.45
5.4.380.0070.05318.50
5.4.370.0070.03718.63
5.4.360.0130.04718.77
5.4.350.0090.03611.97
5.4.340.0090.05411.96
5.4.320.0050.03812.45
5.4.310.0070.05112.45
5.4.300.0040.05012.45
5.4.290.0070.04012.45
5.4.280.0070.03412.35
5.4.270.0070.04212.35
5.4.260.0030.04612.35
5.4.250.0090.04512.34
5.4.240.0060.03712.35
5.4.230.0070.04312.34
5.4.220.0050.04112.34
5.4.210.0100.03212.34
5.4.200.0050.04012.34
5.4.190.0040.03912.33
5.4.180.0080.03612.34
5.4.170.0060.03612.35
5.4.160.0130.03312.34
5.4.150.0060.03512.34
5.4.140.0090.04112.02
5.4.130.0090.03712.01
5.4.120.0080.04711.97
5.4.110.0060.03711.96
5.4.100.0070.03611.97
5.4.90.0080.03811.96
5.4.80.0030.04011.96
5.4.70.0030.03811.96
5.4.60.0140.05011.96
5.4.50.0100.04411.96
5.4.40.0060.04011.95
5.4.30.0040.03811.94
5.4.20.0060.03711.95
5.4.10.0070.04911.95
5.4.00.0130.04011.44
5.3.290.0080.05112.80
5.3.280.0100.04612.71
5.3.270.0080.04912.73
5.3.260.0100.04912.72
5.3.250.0090.05212.71
5.3.240.0070.03812.72
5.3.230.0070.03812.71
5.3.220.0070.03712.68
5.3.210.0050.04012.68
5.3.200.0030.04012.68
5.3.190.0030.04212.68
5.3.180.0050.03912.67
5.3.170.0070.03612.67
5.3.160.0040.03812.67
5.3.150.0080.04312.67
5.3.140.0100.04212.66
5.3.130.0070.03812.66
5.3.120.0060.03912.66
5.3.110.0070.03912.66
5.3.100.0070.03812.12
5.3.90.0040.04112.08
5.3.80.0030.03912.07
5.3.70.0020.04112.07
5.3.60.0060.03712.06
5.3.50.0060.03912.00
5.3.40.0040.04012.00
5.3.30.0130.03611.95
5.3.20.0030.03811.72
5.3.10.0100.05011.69
5.3.00.0100.04811.68
5.2.170.0090.0399.18
5.2.160.0040.0379.18
5.2.150.0060.0299.18
5.2.140.0050.0309.17
5.2.130.0070.0279.13
5.2.120.0030.0319.14
5.2.110.0080.0299.14
5.2.100.0040.0299.14
5.2.90.0040.0319.14
5.2.80.0040.0319.13
5.2.70.0050.0309.13
5.2.60.0050.0309.09
5.2.50.0050.0429.06
5.2.40.0050.0289.04
5.2.30.0050.0319.01
5.2.20.0050.0299.00
5.2.10.0050.0278.92
5.2.00.0030.0318.78
5.1.60.0010.0288.07
5.1.50.0060.0238.06
5.1.40.0030.0268.04
5.1.30.0040.0338.39
5.1.20.0050.0288.41
5.1.10.0060.0248.14
5.1.00.0030.0298.14
5.0.50.0030.0216.61
5.0.40.0060.0176.48
5.0.30.0050.0316.29
5.0.20.0070.0236.26
5.0.10.0040.0216.24
5.0.00.0050.0306.23
4.4.90.0040.0154.77
4.4.80.0040.0144.76
4.4.70.0020.0164.76
4.4.60.0010.0194.75
4.4.50.0020.0164.77
4.4.40.0040.0254.71
4.4.30.0020.0164.76
4.4.20.0030.0164.85
4.4.10.0020.0174.85
4.4.00.0030.0254.76
4.3.110.0010.0184.67
4.3.100.0020.0154.66
4.3.90.0020.0164.63
4.3.80.0020.0264.59
4.3.70.0020.0234.63
4.3.60.0020.0184.63
4.3.50.0080.0174.63
4.3.40.0060.0264.53
4.3.30.0030.0173.29
4.3.20.0030.0173.27
4.3.10.0040.0143.23
4.3.00.0130.0208.35

preferences:
67.82 ms | 401 KiB | 5 Q