3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * Which one is greatest? */ $inf = INF; $array = array(); $object = (object) $array; $InfGreaterThanArray = ($inf > $array); $InfGreaterThanObject = ($inf > $object); $arrayGreaterThanInf = ($array > $inf); $arrayGreaterThanObject = ($array > $object); $objectGreaterThanInf = ($object > $inf); $objectGreaterThanArray = ($object > array()); // Test1: Is INF greatest? # boolean(false) var_dump($InfIsGreatest = $InfGreaterThanObject and $InfGreaterThanArray); // Test2: Is Array greatest? # boolean(false) var_dump($arrayIsGreatest = $arrayGreaterThanInf and $arrayGreaterThanObject); // Test3: Is Object greatest? # boolean(false) var_dump($objectIsGreatest = $objectGreaterThanInf and $objectGreaterThanArray); // Test4: Undefined? # boolean(true) var_dump( $undefined = ( ($InfIsGreatest and $InfIsGreatest == $arrayIsGreatest) || ($arrayIsGreatest and $arrayIsGreatest == $objectIsGreatest) || (!$InfIsGreatest and $InfIsGreatest == $arrayIsGreatest and $InfIsGreatest == $objectIsGreatest) ) );

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.70.0040.01116.63
8.3.60.0070.00718.68
8.3.50.0130.00821.15
8.3.40.0140.00018.68
8.3.30.0070.00718.58
8.3.20.0000.00818.69
8.3.10.0040.00420.83
8.3.00.0000.00721.60
8.2.180.0080.00816.38
8.2.170.0110.00422.96
8.2.160.0070.00720.47
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0050.00326.16
8.2.120.0000.00721.11
8.2.110.0000.01019.30
8.2.100.0070.00619.70
8.2.90.0040.00418.03
8.2.80.0000.00817.97
8.2.70.0000.00817.63
8.2.60.0040.00417.90
8.2.50.0040.00418.07
8.2.40.0040.00418.34
8.2.30.0000.00721.21
8.2.20.0030.00617.56
8.2.10.0040.00417.74
8.2.00.0060.00317.61
8.1.280.0130.01025.92
8.1.270.0040.00423.99
8.1.260.0110.00726.35
8.1.250.0040.00428.09
8.1.240.0100.00022.59
8.1.230.0070.00320.97
8.1.220.0030.00617.74
8.1.210.0030.00618.77
8.1.200.0030.00617.35
8.1.190.0000.00717.40
8.1.180.0050.00318.10
8.1.170.0000.00818.56
8.1.160.0030.00518.87
8.1.150.0000.00818.53
8.1.140.0000.00817.48
8.1.130.0000.00817.43
8.1.120.0080.00317.51
8.1.110.0030.00517.43
8.1.100.0000.00817.43
8.1.90.0040.00417.36
8.1.80.0060.00317.51
8.1.70.0000.00717.45
8.1.60.0040.00417.54
8.1.50.0040.00417.35
8.1.40.0000.00817.52
8.1.30.0080.00017.68
8.1.20.0000.00817.59
8.1.10.0080.00017.37
8.1.00.0080.00317.30
8.0.300.0080.00019.85
8.0.290.0040.00417.18
8.0.280.0030.00318.32
8.0.270.0000.00717.25
8.0.260.0040.00416.87
8.0.250.0040.00417.03
8.0.240.0090.00016.98
8.0.230.0000.00717.02
8.0.220.0030.00316.93
8.0.210.0040.00416.90
8.0.200.0030.00317.04
8.0.190.0080.00016.90
8.0.180.0050.00217.03
8.0.170.0040.00416.95
8.0.160.0040.00416.87
8.0.150.0000.00716.89
8.0.140.0030.00516.91
8.0.130.0050.00013.34
8.0.120.0050.00316.92
8.0.110.0000.00816.88
8.0.100.0030.00516.90
8.0.90.0000.00916.99
8.0.80.0040.01216.87
8.0.70.0000.00816.77
8.0.60.0070.00016.94
8.0.50.0050.00216.91
8.0.30.0100.00917.05
8.0.20.0100.00917.40
8.0.10.0000.00816.93
8.0.00.0090.01116.86
7.4.330.0050.00016.85
7.4.320.0000.00616.50
7.4.300.0030.00316.47
7.4.290.0030.00316.48
7.4.280.0000.00716.40
7.4.270.0040.00416.59
7.4.260.0000.00513.20
7.4.250.0000.00716.48
7.4.240.0000.00816.45
7.4.230.0000.00716.42
7.4.220.0110.00716.51
7.4.210.0080.00816.54
7.4.200.0030.00316.59
7.4.190.0050.00216.55
7.4.160.0110.01116.64
7.4.150.0030.01417.40
7.4.140.0070.01017.86
7.4.130.0060.01116.58
7.4.120.0140.00416.62
7.4.110.0060.01016.54
7.4.100.0130.00316.40
7.4.90.0070.01016.57
7.4.80.0060.01519.39
7.4.70.0150.00316.58
7.4.60.0130.00316.59
7.4.50.0000.00816.25
7.4.40.0070.01022.77
7.4.30.0060.01216.63
7.4.00.0060.00915.15
7.3.330.0030.00213.23
7.3.320.0000.00513.11
7.3.310.0070.00016.46
7.3.300.0070.00016.36
7.3.290.0100.00916.28
7.3.280.0110.00616.37
7.3.270.0070.01117.40
7.3.260.0150.00218.24
7.3.250.0060.01116.46
7.3.240.0150.00016.30
7.3.230.0180.00416.46
7.3.210.0100.00716.44
7.3.200.0060.01219.39
7.3.190.0060.01216.43
7.3.180.0100.00516.43
7.3.170.0090.00616.34
7.3.160.0060.00916.38
7.3.120.0060.01014.84
7.2.330.0150.00316.51
7.2.320.0130.01016.39
7.2.310.0100.00716.65
7.2.300.0030.01316.69
7.2.290.0090.00916.41
7.2.60.0070.00716.56
7.2.00.0040.00819.04
7.1.200.0090.00015.80
7.1.100.0070.00417.61
7.1.70.0000.00717.32
7.1.60.0100.01619.17
7.1.50.0100.00716.77
7.1.00.0070.03022.52
7.0.200.0040.00416.89
7.0.140.0030.07721.95
7.0.60.0170.07719.94
7.0.50.0070.07317.82
7.0.40.0070.07720.21
7.0.30.0530.06020.04
7.0.20.0230.07320.33
7.0.10.0330.08020.08
7.0.00.0100.04320.31
5.6.280.0000.07721.09
5.6.210.0070.06020.50
5.6.200.0070.06018.12
5.6.190.0170.04320.63
5.6.180.0330.07320.45
5.6.170.0500.06320.44
5.6.160.0100.08320.49
5.6.150.0100.07718.18
5.6.140.0070.06718.12
5.6.130.0030.05318.17
5.6.120.0170.07721.03
5.6.110.0170.05721.11
5.6.100.0000.05020.88
5.6.90.0030.08721.09
5.6.80.0170.07320.47
5.6.70.0200.04020.40
5.5.350.0330.07320.38
5.5.340.0100.06717.92
5.5.330.0000.04720.40
5.5.320.0030.05320.21
5.5.310.0200.03320.16
5.5.300.0070.05317.95
5.5.290.0100.07317.87
5.5.280.0070.08020.84
5.5.270.0070.05720.96
5.5.260.0070.07720.81
5.5.250.0070.07320.44
5.5.240.0070.08020.25
5.4.450.0300.04319.41
5.4.440.0400.07019.21
5.4.430.0230.04019.41
5.4.420.0430.07319.58
5.4.410.0370.06719.36
5.4.400.0370.06719.09
5.4.390.0400.07718.93
5.4.380.0430.06718.79
5.4.370.0430.07018.95
5.4.360.0430.07019.10
5.4.350.0470.04019.09
5.4.340.0330.03718.95
5.4.320.0400.07018.79
5.4.310.0370.07019.25
5.4.300.0370.03319.09
5.4.290.0270.04018.92
5.4.280.0400.04319.10
5.4.270.0430.06719.15
5.4.260.0330.03718.91
5.4.250.0370.07019.08
5.4.240.0430.06719.23
5.4.230.0430.06319.05
5.4.220.0470.06319.15
5.4.210.0400.06718.78
5.4.200.0370.04018.93
5.4.190.0500.06019.12
5.4.180.0330.03719.07
5.4.170.0400.04719.15
5.4.160.0430.05018.76
5.4.150.0400.05719.14
5.4.140.0330.03316.38
5.4.130.0400.06316.37
5.4.120.0400.06316.43
5.4.110.0400.03016.39
5.4.100.0400.07316.49
5.4.90.0470.06316.39
5.4.80.0330.04016.48
5.4.70.0300.04316.39
5.4.60.0370.05316.43
5.4.50.0200.04016.45
5.4.40.0330.07016.36
5.4.30.0300.06716.19
5.4.20.0470.04316.27
5.4.10.0370.06716.46
5.4.00.0330.04715.76
5.3.290.0400.06314.54
5.3.280.0330.05014.52
5.3.270.0430.05314.42
5.3.260.0370.05014.43
5.3.250.0270.04014.43
5.3.240.0370.04014.45
5.3.230.0400.07314.45
5.3.220.0300.04714.42
5.3.210.0500.06014.59
5.3.200.0570.06014.52
5.3.190.0470.05714.44
5.3.180.0400.04314.47
5.3.170.0330.05314.65
5.3.160.0270.04014.42
5.3.150.0270.03314.40
5.3.140.0330.07014.40
5.3.130.0370.05314.63
5.3.120.0400.05714.44
5.3.110.0530.04014.41
5.3.100.0300.07313.91
5.3.90.0400.06713.89
5.3.80.0370.05713.96
5.3.70.0370.05314.00
5.3.60.0470.05313.95
5.3.50.0300.03313.74
5.3.40.0270.03713.88
5.3.30.0430.06013.86
5.3.20.0470.05013.52
5.3.10.0400.06713.53
5.3.00.0400.04713.52
5.2.170.0230.03012.75
5.2.160.0270.02312.75
5.2.150.0200.03012.75
5.2.140.0200.04712.75
5.2.130.0370.05012.75
5.2.120.0270.04712.75
5.2.110.0400.05712.75
5.2.100.0330.05312.75
5.2.90.0330.05312.75
5.2.80.0370.04012.75
5.2.70.0300.03012.75
5.2.60.0330.04712.75
5.2.50.0230.03712.75
5.2.40.0370.04712.75
5.2.30.0230.03012.75
5.2.20.0200.03312.75
5.2.10.0300.04712.75
5.2.00.0370.04312.75
5.1.60.0200.02712.75
5.1.50.0300.04712.75
5.1.40.0370.03312.75
5.1.30.0270.05312.75
5.1.20.0270.03312.75
5.1.10.0230.03312.75
5.1.00.0300.02712.75
5.0.50.0230.03312.75
5.0.40.0130.02012.75
5.0.30.0130.05012.75
5.0.20.0130.02312.75
5.0.10.0130.03012.75
5.0.00.0200.03312.75
4.4.90.0130.01312.75
4.4.80.0100.02012.75
4.4.70.0100.04012.75
4.4.60.0170.02712.75
4.4.50.0130.03712.75
4.4.40.0130.03012.75
4.4.30.0170.02012.75
4.4.20.0130.02312.75
4.4.10.0200.01712.75
4.4.00.0170.02712.75
4.3.110.0100.03712.75
4.3.100.0130.01712.75
4.3.90.0200.03012.75
4.3.80.0270.02012.75
4.3.70.0100.03312.75
4.3.60.0230.01012.75
4.3.50.0200.02012.75
4.3.40.0130.03712.75
4.3.30.0070.02012.75
4.3.20.0070.02012.75
4.3.10.0170.01012.75
4.3.00.0100.03012.75

preferences:
45.24 ms | 401 KiB | 5 Q