3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "Strings are sometimes numbers?\n"; $number = "2sdfsdfjoi"; var_dump($number == 2); // = true (wat?) $number = "22sdfsdfjoi"; var_dump($number == 2); // = false (makes sense...) var_dump($number == 22); // = true (wat?) echo "Strings are always == true\n"; var_dump($number == true); // string = true (ugghh) echo "The triple equals === is the only way to be sure\n"; var_dump($number === 22); // === the only way to be sure.

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.01018.56
8.3.50.0100.00822.05
8.3.40.0070.00718.77
8.3.30.0110.00318.87
8.3.20.0070.00020.34
8.3.10.0000.00823.34
8.3.00.0040.00418.89
8.2.180.0140.00418.29
8.2.170.0040.01122.96
8.2.160.0100.00320.39
8.2.150.0080.00024.18
8.2.140.0030.00524.66
8.2.130.0040.00426.16
8.2.120.0080.00019.64
8.2.110.0070.00322.25
8.2.100.0000.01217.72
8.2.90.0000.00817.63
8.2.80.0080.00018.04
8.2.70.0040.00417.80
8.2.60.0080.00418.09
8.2.50.0080.00018.10
8.2.40.0040.00419.34
8.2.30.0040.00419.29
8.2.20.0050.00317.61
8.2.10.0040.00417.93
8.2.00.0000.00817.75
8.1.280.0040.01125.92
8.1.270.0080.00018.95
8.1.260.0070.00026.35
8.1.250.0000.00728.09
8.1.240.0040.00423.92
8.1.230.0030.00819.09
8.1.220.0060.00317.74
8.1.210.0000.00918.77
8.1.200.0040.00417.35
8.1.190.0000.01017.13
8.1.180.0050.00318.10
8.1.170.0050.00318.63
8.1.160.0040.00418.99
8.1.150.0000.00718.91
8.1.140.0000.00717.55
8.1.130.0000.00717.77
8.1.120.0070.00017.35
8.1.110.0000.00717.48
8.1.100.0040.00417.46
8.1.90.0080.00017.45
8.1.80.0000.00717.41
8.1.70.0030.00317.34
8.1.60.0030.00617.61
8.1.50.0050.00317.50
8.1.40.0050.00217.54
8.1.30.0040.00417.47
8.1.20.0000.00717.71
8.1.10.0060.00317.55
8.1.00.0080.00017.49
8.0.300.0000.00719.63
8.0.290.0000.00816.75
8.0.280.0080.00018.35
8.0.270.0000.00717.13
8.0.260.0030.00317.20
8.0.250.0040.00416.95
8.0.240.0000.00816.96
8.0.230.0000.00716.98
8.0.220.0030.00316.81
8.0.210.0030.00316.91
8.0.200.0050.00216.92
8.0.190.0040.00417.02
8.0.180.0000.00716.94
8.0.170.0040.00416.82
8.0.160.0000.00716.80
8.0.150.0000.00716.87
8.0.140.0050.00316.89
8.0.130.0050.00013.27
8.0.120.0040.00416.86
8.0.110.0000.00716.82
8.0.100.0040.00416.94
8.0.90.0000.00717.00
8.0.80.0070.00716.84
8.0.70.0070.00016.75
8.0.60.0050.00216.69
8.0.50.0000.00716.77
8.0.30.0120.00817.22
8.0.20.0060.01217.40
8.0.10.0070.00016.92
8.0.00.0090.01216.65
7.4.330.0030.00315.07
7.4.320.0000.00616.64
7.4.300.0030.00316.64
7.4.290.0040.00716.51
7.4.280.0000.00716.49
7.4.270.0000.00716.52
7.4.260.0090.00016.35
7.4.250.0000.00816.46
7.4.240.0040.00316.64
7.4.230.0070.00016.36
7.4.220.0070.01216.50
7.4.210.0070.00716.54
7.4.200.0000.00916.41
7.4.160.0100.00516.46
7.4.150.0130.00617.40
7.4.140.0100.01017.86
7.4.130.0130.00716.55
7.4.120.0120.00516.41
7.4.110.0130.01016.54
7.4.100.0120.00616.50
7.4.90.0060.01116.57
7.4.80.0090.01019.39
7.4.70.0110.00816.54
7.4.60.0100.00716.42
7.4.50.0000.00816.23
7.4.40.0000.01616.54
7.4.30.0120.00416.60
7.4.00.0100.00715.00
7.3.330.0020.00213.02
7.3.320.0000.00513.20
7.3.310.0020.00516.09
7.3.300.0030.00316.11
7.3.290.0050.00916.31
7.3.280.0070.01316.22
7.3.270.0140.00317.40
7.3.260.0110.00616.44
7.3.250.0110.00616.35
7.3.240.0080.00816.28
7.3.230.0070.01516.43
7.3.210.0090.00916.22
7.3.200.0100.00719.39
7.3.190.0090.00616.47
7.3.180.0120.00916.45
7.3.170.0110.00816.42
7.3.160.0080.00816.57
7.2.330.0060.01116.38
7.2.320.0060.01216.25
7.2.310.0000.01916.43
7.2.300.0030.01516.56
7.2.290.0120.00616.53
7.2.00.0130.00819.27
7.1.100.0000.01318.08
7.1.70.0070.00717.22
7.1.60.0170.00719.22
7.1.50.0100.01017.06
7.1.00.0000.08022.36
7.0.200.0000.00816.52
7.0.140.0000.03721.95
7.0.60.0030.06319.93
7.0.50.0100.04717.89
7.0.40.0070.08020.30
7.0.30.0200.04020.17
7.0.20.0270.04720.09
7.0.10.0070.04720.20
7.0.00.0100.03320.44
5.6.280.0070.06721.12
5.6.210.0130.07020.68
5.6.200.0100.06718.12
5.6.190.0000.05320.41
5.6.180.0330.04320.45
5.6.170.0200.04020.54
5.6.160.0130.08020.52
5.6.150.0100.04018.08
5.6.140.0070.04718.21
5.6.130.0030.08318.11
5.6.120.0100.08021.11
5.6.110.0030.04321.03
5.6.100.0070.05720.99
5.6.90.0030.04021.10
5.6.80.0100.03320.28
5.5.350.0100.03720.43
5.5.340.0100.07717.96
5.5.330.0100.07320.20
5.5.320.0130.08720.51
5.5.310.0300.05720.29
5.5.300.0100.07717.98
5.5.290.0000.08317.95
5.5.280.0100.03320.66
5.5.270.0030.06320.71
5.5.260.0230.05720.75
5.5.250.0070.08320.61
5.5.240.0000.07320.36
5.4.450.0770.06019.49
5.4.440.0670.05019.25
5.4.430.0400.06319.54
5.4.420.0330.06019.48
5.4.410.0370.06719.02
5.4.400.0570.04718.90
5.4.390.0470.06719.09
5.4.380.1000.06318.69
5.4.370.1030.04718.64
5.4.360.0870.06018.63
5.4.350.0930.05718.73
5.4.340.1070.06018.56
5.4.320.0970.06018.47
5.4.310.0970.08318.71
5.4.300.0900.05018.66
5.4.290.0900.05318.48
5.4.280.0870.05718.48
5.4.270.0970.07018.68
5.4.260.0930.05318.54
5.4.250.1170.06718.73
5.4.240.1100.06718.75
5.4.230.1200.06718.60
5.4.220.0870.07018.74
5.4.210.0970.06318.62
5.4.200.1130.06716.39
5.4.190.1030.05318.70
5.4.180.1000.06318.63
5.4.170.1200.06718.46
5.4.160.1100.05718.67
5.4.150.1000.06018.39
5.4.140.1170.06316.14
5.4.130.0870.06016.20
5.4.120.0570.05716.11
5.4.110.0200.06016.03
5.4.100.0230.06716.27
5.4.90.0270.05716.34
5.4.80.0900.04316.01
5.4.70.0970.06316.24
5.4.60.0930.05016.09
5.4.50.0830.05716.25
5.4.40.0930.05015.97
5.4.30.0870.05715.99
5.4.20.0900.05016.09
5.4.10.0900.05316.10
5.4.00.0870.05715.57
5.3.290.0900.05714.69
5.3.280.0870.06714.60
5.3.270.0930.05014.61
5.3.260.0900.06314.67
5.3.250.0900.05014.56
5.3.240.0830.06014.53
5.3.230.0870.05314.66
5.3.220.0900.05014.59
5.3.210.1000.04714.53
5.3.200.0930.04714.56
5.3.190.0870.05314.54
5.3.180.0970.04314.54
5.3.170.0870.04714.49
5.3.160.1000.04314.65
5.3.150.0900.05014.47
5.3.140.0930.05314.46
5.3.130.0970.06314.59
5.3.120.0900.05314.51
5.3.110.1130.06014.54
5.3.100.0930.04714.07
5.3.90.0970.04713.93
5.3.80.1000.05713.94
5.3.70.0970.07713.93
5.3.60.0830.05713.95
5.3.50.0870.05313.86
5.3.40.0830.05313.93
5.3.30.0970.05313.92
5.3.20.0930.05313.59
5.3.10.1030.07713.58
5.3.00.0900.05013.53
5.2.170.0770.03711.28
5.2.160.0700.04311.20
5.2.150.0730.04311.09
5.2.140.0700.04711.12
5.2.130.0800.03011.01
5.2.120.0870.03311.09
5.2.110.0730.04311.26
5.2.100.0830.05011.11
5.2.90.0730.04311.08
5.2.80.0730.04711.05
5.2.70.0770.04311.23
5.2.60.0700.04311.07
5.2.50.0770.04011.06
5.2.40.0470.05010.95
5.2.30.0600.04710.97
5.2.20.0630.03710.92
5.2.10.0600.04010.82
5.2.00.0600.03710.77
5.1.60.0530.04010.05
5.1.50.0600.04010.05
5.1.40.0570.03710.09
5.1.30.0530.04010.36
5.1.20.0530.04010.48
5.1.10.0570.03710.13
5.1.00.0500.04010.05
5.0.50.0370.0238.52
5.0.40.0330.0308.47
5.0.30.0330.0508.26
5.0.20.0300.0278.21
5.0.10.0300.0278.23
5.0.00.0370.0338.33
4.4.90.0270.0235.93
4.4.80.0330.0305.89
4.4.70.0330.0205.88
4.4.60.0300.0205.87
4.4.50.0330.0235.86
4.4.40.0300.0335.86
4.4.30.0330.0305.81
4.4.20.0430.0235.87
4.4.10.0230.0305.95
4.4.00.0330.0305.91
4.3.110.0230.0275.83
4.3.100.0300.0205.78
4.3.90.0270.0235.79
4.3.80.0270.0375.79
4.3.70.0200.0305.81
4.3.60.0300.0205.83
4.3.50.0330.0235.79
4.3.40.0270.0375.79
4.3.30.0100.0274.59
4.3.20.0170.0234.57
4.3.10.0130.0234.47
4.3.00.0100.0237.58

preferences:
54.88 ms | 401 KiB | 5 Q