3v4l.org

run code in 300+ PHP versions simultaneously
<?php // http://gathering.tweakers.net/forum/list_message/41881215#41881215 function foo($string1, $string2) { /* Retourneert true dan en slechts dan wanneer de twee argumenten strings zijn en het eerste argument lexicografisch kleiner is. */ return is_string($string1) && is_string($string2) && $string1 < $string2; } var_dump( foo(1,2), foo('1','2'), foo('a','b'), foo('b','a'), foo('ab','ab'), foo('abc','ab'), foo('2aa','2bb') );

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.01118.43
8.3.50.0110.00722.05
8.3.40.0060.00918.70
8.3.30.0150.00318.90
8.3.20.0070.00020.29
8.3.10.0040.00421.95
8.3.00.0040.00422.46
8.2.180.0150.00416.50
8.2.170.0100.01022.96
8.2.160.0140.00019.08
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0080.00026.16
8.2.120.0040.00419.54
8.2.110.0040.00422.08
8.2.100.0120.00017.72
8.2.90.0000.00917.75
8.2.80.0030.00517.97
8.2.70.0030.00517.79
8.2.60.0000.00918.09
8.2.50.0040.00418.10
8.2.40.0040.00418.03
8.2.30.0000.00817.96
8.2.20.0040.00417.63
8.2.10.0040.00417.64
8.2.00.0090.00017.54
8.1.280.0070.00725.92
8.1.270.0080.00018.37
8.1.260.0050.00326.35
8.1.250.0070.00028.09
8.1.240.0060.00323.79
8.1.230.0040.00719.00
8.1.220.0040.00417.74
8.1.210.0030.00518.77
8.1.200.0040.00817.22
8.1.190.0080.00017.22
8.1.180.0000.00818.10
8.1.170.0050.00318.66
8.1.160.0000.00722.05
8.1.150.0000.00718.54
8.1.140.0050.00217.36
8.1.130.0050.00317.79
8.1.120.0080.00017.39
8.1.110.0000.00717.38
8.1.100.0040.00417.47
8.1.90.0000.00717.33
8.1.80.0000.00717.32
8.1.70.0000.00617.37
8.1.60.0000.00917.52
8.1.50.0050.00517.46
8.1.40.0040.00417.49
8.1.30.0060.00317.50
8.1.20.0080.00017.58
8.1.10.0040.00417.41
8.1.00.0030.00617.23
8.0.300.0000.00921.51
8.0.290.0060.00316.63
8.0.280.0030.00318.29
8.0.270.0000.00717.14
8.0.260.0000.00716.84
8.0.250.0050.00216.83
8.0.240.0080.00016.93
8.0.230.0030.00316.79
8.0.220.0030.00316.86
8.0.210.0070.00016.92
8.0.200.0000.00616.84
8.0.190.0040.00416.96
8.0.180.0000.01016.89
8.0.170.0050.00316.89
8.0.160.0000.00716.74
8.0.150.0070.00016.82
8.0.140.0040.00416.85
8.0.130.0030.00313.27
8.0.120.0040.00416.80
8.0.110.0050.00216.72
8.0.100.0040.00416.89
8.0.90.0040.00316.81
8.0.80.0150.00016.77
8.0.70.0000.00716.69
8.0.60.0070.00016.98
8.0.50.0050.00316.82
8.0.30.0090.00917.05
8.0.20.0100.01117.40
8.0.10.0040.00416.94
8.0.00.0110.00916.72
7.4.330.0060.00015.00
7.4.320.0000.00716.56
7.4.300.0060.00016.55
7.4.290.0070.00016.38
7.4.280.0000.00616.56
7.4.270.0030.00316.61
7.4.260.0030.00316.56
7.4.250.0070.00016.51
7.4.240.0040.00316.54
7.4.230.0030.00316.43
7.4.220.0060.01816.44
7.4.210.0080.01016.57
7.4.200.0040.00416.55
7.4.190.0040.00416.69
7.4.160.0000.01716.31
7.4.150.0180.00617.40
7.4.140.0180.00417.86
7.4.130.0130.00816.43
7.4.120.0060.01316.44
7.4.110.0140.00316.39
7.4.100.0080.01716.45
7.4.90.0060.01216.53
7.4.80.0090.00919.39
7.4.70.0060.01216.48
7.4.60.0060.00916.47
7.4.50.0040.00016.37
7.4.40.0030.01322.77
7.4.30.0000.01516.55
7.4.00.0110.00714.75
7.3.330.0000.00613.33
7.3.320.0050.00013.29
7.3.310.0030.00316.37
7.3.300.0070.00016.34
7.3.290.0070.00716.38
7.3.280.0050.00916.32
7.3.270.0110.00617.40
7.3.260.0070.01016.38
7.3.250.0180.00516.38
7.3.240.0030.01416.59
7.3.230.0100.00716.42
7.3.210.0040.01516.39
7.3.200.0040.01319.39
7.3.190.0150.00616.24
7.3.180.0090.00916.54
7.3.170.0170.00016.61
7.3.160.0130.00316.45
7.3.120.0090.00814.84
7.3.110.0070.01114.84
7.3.100.0080.00815.07
7.3.90.0030.00814.84
7.3.80.0030.01214.97
7.3.70.0060.00514.79
7.3.60.0070.00614.85
7.3.50.0050.00714.69
7.3.40.0070.00514.84
7.3.30.0060.00814.68
7.3.20.0010.01116.63
7.3.10.0070.00416.59
7.3.00.0070.00716.63
7.2.330.0070.01116.31
7.2.320.0000.02016.65
7.2.310.0120.00616.28
7.2.300.0030.01316.66
7.2.290.0130.00316.48
7.2.250.0120.00714.78
7.2.240.0070.01315.07
7.2.230.0060.00814.98
7.2.220.0020.01314.99
7.2.210.0080.00714.89
7.2.200.0020.01115.02
7.2.190.0090.00614.96
7.2.180.0050.01014.90
7.2.170.0040.00814.86
7.1.330.0030.01015.65
7.1.320.0040.00915.57
7.1.310.0070.00915.63
7.1.300.0020.01215.78
7.1.290.0070.00615.55
7.1.280.0080.00315.73
7.1.270.0020.00915.62
7.1.260.0040.00815.75
7.1.70.0000.00817.16
7.1.60.0090.01619.82
7.1.50.0040.01516.95
7.1.00.0100.07022.54
7.0.200.0000.00716.58
7.0.140.0030.07321.99
7.0.60.0100.08019.93
7.0.50.0170.07317.89
7.0.40.0030.09020.10
7.0.30.0470.05720.30
7.0.20.0230.04720.23
7.0.10.0130.08320.15
7.0.00.0000.04320.11
5.6.280.0100.06720.91
5.6.210.0100.07320.77
5.6.200.0030.04018.15
5.6.190.0070.08320.61
5.6.180.0170.04320.33
5.6.170.0300.08020.54
5.6.160.0030.04020.39
5.6.150.0170.06718.19
5.6.140.0070.04318.18
5.6.130.0100.03318.18
5.6.120.0070.09021.02
5.6.110.0070.07021.13
5.6.100.0070.07321.11
5.6.90.0130.04321.08
5.6.80.0030.08320.54
5.5.350.0100.06020.32
5.5.340.0100.07717.98
5.5.330.0000.04320.29
5.5.320.0230.05020.14
5.5.310.0370.05320.34
5.5.300.0070.05318.02
5.5.290.0030.08017.98
5.5.280.0100.08020.77
5.5.270.0000.08020.87
5.5.260.0100.05320.72
5.5.250.0130.07720.46
5.5.240.3670.03720.19
5.4.450.0630.07719.48
5.4.440.0770.05319.58
5.4.430.0630.06019.60
5.4.420.0430.05319.45
5.4.410.0800.05319.50
5.4.400.0400.06318.80
5.4.390.0100.06318.44
5.4.380.0100.07318.81
5.4.370.0170.05018.50
5.4.360.0230.04318.53
5.4.350.0130.06018.79
5.4.340.0170.05318.52
5.4.320.0070.03512.50
5.4.310.0060.04012.50
5.4.300.0050.03812.50
5.4.290.0070.03612.50
5.4.280.0060.03512.39
5.4.270.0080.03412.40
5.4.260.0030.04012.39
5.4.250.0170.06719.01
5.4.240.0130.07018.99
5.4.230.0100.07018.88
5.4.220.0130.05718.90
5.4.210.0130.06318.73
5.4.200.0100.05018.93
5.4.190.0130.07319.06
5.4.180.0030.05718.79
5.4.170.0000.06318.93
5.4.160.0130.04718.93
5.4.150.0070.07018.99
5.4.140.0070.05716.42
5.4.130.0200.06016.43
5.4.120.0030.05716.32
5.4.110.0170.06316.42
5.4.100.0100.06716.41
5.4.90.0070.05716.42
5.4.80.0130.05716.33
5.4.70.0130.04716.54
5.4.60.0130.04316.24
5.4.50.0030.07316.32
5.4.40.0070.06016.40
5.4.30.0100.04716.31
5.4.20.0070.05016.55
5.4.10.0070.05016.42
5.4.00.0130.05315.98
5.3.290.0060.03912.80
5.3.280.0070.05314.81
5.3.270.0030.05714.70
5.3.260.0130.06714.59
5.3.250.0030.08014.70
5.3.240.0070.05714.60
5.3.230.0000.06014.66
5.3.220.0130.06014.56
5.3.210.0100.05014.63
5.3.200.0100.05014.57
5.3.190.0100.06714.59
5.3.180.0070.07014.64
5.3.170.0130.04714.70
5.3.160.0070.05714.64
5.3.150.0130.06014.55
5.3.140.0100.04714.71
5.3.130.0100.05314.37
5.3.120.0100.05014.71
5.3.110.0070.07714.70
5.3.100.0030.06014.13
5.3.90.0170.05714.18
5.3.80.0200.05314.24
5.3.70.0070.05314.00
5.3.60.0070.07014.00
5.3.50.0170.05014.03
5.3.40.0030.07014.17
5.3.30.0170.05713.89
5.3.20.0100.06313.71
5.3.10.0070.06013.72
5.3.00.0130.05313.70
5.2.170.0070.05011.21
5.2.160.0070.05011.13
5.2.150.0100.04311.30
5.2.140.0070.06311.21
5.2.130.0130.04711.10
5.2.120.0030.05311.28
5.2.110.0100.03311.32
5.2.100.0030.04011.18
5.2.90.0070.03711.16
5.2.80.0130.04311.17
5.2.70.0030.04311.17
5.2.60.0100.04011.14
5.2.50.0100.03711.11
5.2.40.0130.03011.00
5.2.30.0100.04011.05
5.2.20.0130.03711.14
5.2.10.0070.05310.77
5.2.00.0100.03310.55
5.1.60.0000.03710.01
5.1.50.0100.03010.15
5.1.40.0030.0409.95
5.1.30.0070.04010.33
5.1.20.0070.03310.36
5.1.10.0130.02710.05
5.1.00.0030.04010.12
5.0.50.0030.0308.53
5.0.40.0200.0278.25
5.0.30.0070.0508.14
5.0.20.0000.0308.20
5.0.10.0030.0278.32
5.0.00.0000.0438.22
4.4.90.0000.0237.31
4.4.80.0000.0237.31
4.4.70.0000.0237.31
4.4.60.0000.0237.31
4.4.50.0100.0137.31
4.4.40.0000.0377.31
4.4.30.0030.0207.31
4.4.20.0030.0277.31
4.4.10.0030.0207.31
4.4.00.0030.0377.31
4.3.110.0030.0277.31
4.3.100.0000.0237.31
4.3.90.0030.0277.31
4.3.80.0030.0307.31
4.3.70.0000.0237.31
4.3.60.0130.0177.31
4.3.50.0030.0237.31
4.3.40.0030.0337.31
4.3.30.0030.0207.31
4.3.20.0000.0277.31
4.3.10.0030.0277.31
4.3.00.0070.0276.77

preferences:
44.46 ms | 401 KiB | 5 Q