3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "Did you know strings are numbers?\n"; $number = "2sdfsdfjoi"; var_dump($number == 2); // = true (wat?) $number = "22sdfsdfjoi"; var_dump($number == 2); // = false (makes sense...) var_dump($number == 22); // = true (wait, wat?) echo "Strings are also both true and false\n"; var_dump($number == true); // string = true (ugghh) var_dump($number == false); // string also = false (kill me now) 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.40.0110.00418.54
8.3.30.0120.00318.91
8.3.20.0050.00320.21
8.3.10.0080.00023.68
8.3.00.0040.00419.02
8.2.170.0090.00622.96
8.2.160.0100.00320.39
8.2.150.0000.01524.18
8.2.140.0000.00824.66
8.2.130.0070.00026.16
8.2.120.0040.00419.66
8.2.110.0030.00622.11
8.2.100.0090.00317.91
8.2.90.0000.00920.54
8.2.80.0030.00917.97
8.2.70.0040.00417.80
8.2.60.0040.00418.06
8.2.50.0040.00418.10
8.2.40.0080.00021.02
8.2.30.0040.00419.25
8.2.20.0000.00817.61
8.2.10.0000.00918.04
8.2.00.0000.00817.56
8.1.270.0000.00818.74
8.1.260.0090.00026.35
8.1.250.0050.00228.09
8.1.240.0150.00422.50
8.1.230.0070.00420.83
8.1.220.0050.00317.74
8.1.210.0000.00818.95
8.1.200.0040.00417.22
8.1.190.0000.00917.35
8.1.180.0000.00818.10
8.1.170.0050.00318.57
8.1.160.0000.00719.05
8.1.150.0040.00418.80
8.1.140.0040.00417.54
8.1.130.0060.00317.86
8.1.120.0050.00217.41
8.1.110.0000.00817.44
8.1.100.0080.00017.50
8.1.90.0030.00417.38
8.1.80.0040.00417.45
8.1.70.0000.00717.37
8.1.60.0080.00017.52
8.1.50.0040.00417.49
8.1.40.0070.00017.46
8.1.30.0060.00317.56
8.1.20.0000.00717.61
8.1.10.0000.00817.50
8.1.00.0000.00717.33
8.0.300.0070.00019.95
8.0.290.0030.00516.75
8.0.280.0030.00318.35
8.0.270.0030.00317.23
8.0.260.0030.00317.15
8.0.250.0070.00016.96
8.0.240.0040.00416.93
8.0.230.0030.00516.95
8.0.220.0030.00316.88
8.0.210.0060.00016.94
8.0.200.0030.00316.90
8.0.190.0090.00016.94
8.0.180.0040.00416.91
8.0.170.0000.00716.86
8.0.160.0040.00416.87
8.0.150.0070.00016.80
8.0.140.0080.00016.90
8.0.130.0030.00313.29
8.0.120.0030.00616.75
8.0.110.0000.00716.92
8.0.100.0000.00716.69
8.0.90.0080.00016.90
8.0.80.0160.00316.91
8.0.70.0040.00416.87
8.0.60.0040.00416.74
8.0.50.0000.00816.68
8.0.30.0090.01316.92
8.0.20.0110.00717.40
8.0.10.0040.00416.89
8.0.00.0090.00916.78
7.4.330.0050.00015.20
7.4.320.0030.00316.41
7.4.300.0040.00416.49
7.4.290.0030.00616.45
7.4.280.0040.00416.48
7.4.270.0000.00716.60
7.4.260.0090.00016.61
7.4.250.0050.00316.55
7.4.240.0040.00316.54
7.4.230.0030.00316.39
7.4.220.0220.00316.50
7.4.210.0070.00716.54
7.4.200.0060.00316.24
7.4.160.0050.01116.33
7.4.150.0140.00317.40
7.4.140.0100.00717.86
7.4.130.0030.01416.49
7.4.120.0070.01016.36
7.4.110.0040.01716.43
7.4.100.0070.01416.47
7.4.90.0110.00716.29
7.4.80.0100.01019.39
7.4.70.0130.00816.53
7.4.60.0090.01016.51
7.4.50.0000.00816.39
7.4.40.0120.00416.55
7.4.30.0070.01016.38
7.4.00.0000.01614.66
7.3.330.0050.00013.20
7.3.320.0000.00513.20
7.3.310.0030.00316.13
7.3.300.0000.00616.24
7.3.290.0100.00516.25
7.3.280.0090.00816.28
7.3.270.0050.01317.40
7.3.260.0120.00816.49
7.3.250.0100.00716.42
7.3.240.0150.00316.19
7.3.230.0180.00016.41
7.3.210.0030.01416.56
7.3.200.0060.01519.39
7.3.190.0140.00716.52
7.3.180.0220.00016.32
7.3.170.0080.01216.31
7.3.160.0110.00416.37
7.3.10.0080.00816.36
7.3.00.0040.01116.60
7.2.330.0090.00916.53
7.2.320.0110.00516.39
7.2.310.0100.00716.58
7.2.300.0080.00816.22
7.2.290.0060.01116.71
7.2.130.0080.00416.65
7.2.120.0030.01216.80
7.2.110.0120.00316.54
7.2.100.0100.00616.76
7.2.90.0070.00716.95
7.2.80.0030.01116.81
7.2.70.0030.00916.97
7.2.60.0120.00416.86
7.2.50.0000.00916.89
7.2.40.0000.01116.68
7.2.30.0150.00016.87
7.2.20.0050.00516.68
7.2.10.0030.01416.90
7.2.00.0070.01018.20
7.1.250.0040.00415.83
7.1.100.0030.01018.02
7.1.70.0040.00817.25
7.1.60.0070.01819.22
7.1.50.0120.00917.06
7.1.00.0070.07322.37
7.0.200.0000.00816.82
7.0.140.0030.04322.00
7.0.60.0070.04319.79
7.0.50.0130.07317.84
7.0.40.0070.07020.23
7.0.30.0270.08320.06
7.0.20.0300.07320.21
7.0.10.0070.08720.19
7.0.00.0070.04020.17
5.6.280.0170.05720.82
5.6.210.0070.07020.76
5.6.200.0070.05718.19
5.6.190.0070.08020.49
5.6.180.0200.04320.37
5.6.170.0230.06020.38
5.6.160.0030.05720.43
5.6.150.0070.07718.07
5.6.140.0030.04018.18
5.6.130.0070.08018.18
5.6.120.0070.08721.10
5.6.110.0030.04020.89
5.6.100.0070.08721.02
5.6.90.0070.04321.02
5.6.80.0000.04320.38
5.5.350.0200.06020.38
5.5.340.0070.06317.89
5.5.330.0100.05020.15
5.5.320.0170.07020.30
5.5.310.0270.07720.29
5.5.300.0100.08017.90
5.5.290.0100.07717.92
5.5.280.0000.04320.87
5.5.270.0030.08720.88
5.5.260.0070.08720.77
5.5.250.0100.05020.58
5.5.240.0130.07020.36
5.4.450.0430.06019.14
5.4.440.0200.05319.48
5.4.430.0130.05719.14
5.4.420.0130.05719.25
5.4.410.0530.06319.41
5.4.400.0670.04319.20
5.4.390.0500.06019.09
5.4.380.0870.05718.77
5.4.370.0870.06318.64
5.4.360.0800.05318.56
5.4.350.0830.05718.62
5.4.340.0930.05018.65
5.4.320.1130.06018.64
5.4.310.0900.06018.63
5.4.300.1030.06018.64
5.4.290.0930.04318.62
5.4.280.0830.05718.63
5.4.270.0900.05318.64
5.4.260.1200.05718.64
5.4.250.0930.05318.64
5.4.240.0970.07018.63
5.4.230.0900.05318.47
5.4.220.0900.05018.62
5.4.210.0930.05718.67
5.4.200.0770.05316.38
5.4.190.0930.05018.68
5.4.180.0930.05018.54
5.4.170.1070.06018.70
5.4.160.0930.05018.70
5.4.150.0870.05318.55
5.4.140.0830.05316.13
5.4.130.0930.05716.14
5.4.120.0830.05316.14
5.4.110.0930.04716.04
5.4.100.1100.05316.03
5.4.90.0830.05716.07
5.4.80.0830.05316.21
5.4.70.1070.06716.23
5.4.60.0830.05316.11
5.4.50.0930.04316.03
5.4.40.0930.04716.23
5.4.30.0930.06016.24
5.4.20.0970.04016.08
5.4.10.0900.05316.22
5.4.00.0870.05015.55
5.3.290.0900.05314.67
5.3.280.0970.05314.57
5.3.270.0800.06314.58
5.3.260.0870.05314.56
5.3.250.0900.06014.49
5.3.240.0900.05314.63
5.3.230.0930.05314.58
5.3.220.0830.05314.66
5.3.210.0870.05714.53
5.3.200.0870.05314.52
5.3.190.0930.05014.57
5.3.180.1100.06714.63
5.3.170.0800.05714.46
5.3.160.1000.04014.46
5.3.150.0900.05314.55
5.3.140.0800.05714.54
5.3.130.0830.06714.55
5.3.120.1070.06714.50
5.3.110.0870.05314.59
5.3.100.1030.06014.06
5.3.90.0900.05014.02
5.3.80.1070.05313.95
5.3.70.1100.06714.11
5.3.60.0930.04314.00
5.3.50.0970.04713.97
5.3.40.0970.04713.92
5.3.30.0770.05713.89
5.3.20.0930.05313.66
5.3.10.0900.05313.65
5.3.00.0770.05713.54
5.2.170.0630.05311.15
5.2.160.0700.04711.13
5.2.150.0870.05011.12
5.2.140.0870.03711.18
5.2.130.0700.04011.05
5.2.120.0930.04711.05
5.2.110.0670.04711.25
5.2.100.0830.03311.06
5.2.90.0830.04011.14
5.2.80.0830.04011.14
5.2.70.0800.04011.10
5.2.60.0700.04011.08
5.2.50.0730.04311.00
5.2.40.0570.03711.02
5.2.30.0530.04711.13
5.2.20.0600.04010.88
5.2.10.0570.04010.88
5.2.00.0530.04310.81
5.1.60.0600.03010.11
5.1.50.0530.0409.96
5.1.40.0530.04010.07
5.1.30.0530.04010.32
5.1.20.0570.04010.50
5.1.10.0600.03710.10
5.1.00.0770.02710.13
5.0.50.0370.0278.58
5.0.40.0330.0238.45
5.0.30.0270.0438.25
5.0.20.0270.0378.29
5.0.10.0330.0408.20
5.0.00.0370.0538.23
4.4.90.0270.0375.89
4.4.80.0300.0205.90
4.4.70.0400.0275.89
4.4.60.0300.0205.88
4.4.50.0370.0175.91
4.4.40.0300.0335.90
4.4.30.0300.0205.86
4.4.20.0300.0205.93
4.4.10.0270.0235.94
4.4.00.0330.0305.91
4.3.110.0300.0235.83
4.3.100.0270.0235.85
4.3.90.0330.0175.82
4.3.80.0300.0335.77
4.3.70.0370.0275.79
4.3.60.0330.0305.79
4.3.50.0330.0305.88
4.3.40.0300.0335.76
4.3.30.0130.0274.59
4.3.20.0170.0204.62
4.3.10.0130.0274.49
4.3.00.0070.0237.58

preferences:
51.37 ms | 400 KiB | 5 Q