3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = "1XYZ"; $int = 1; $start_int = (int) $string; $start_str = str_replace($start_int, "", $string); $result = $int+$start_int . $start_str; echo $result;

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.5.30.0110.00521.28
8.5.20.0120.00219.51
8.5.10.0090.00916.48
8.5.00.0150.00619.99
8.4.180.0100.01219.60
8.4.170.0070.01620.48
8.4.160.0130.00823.84
8.4.150.0100.00316.71
8.4.140.0120.00917.35
8.4.130.0120.00718.77
8.4.120.0130.00624.00
8.4.110.0060.00322.42
8.4.100.0090.01117.56
8.4.90.0070.01318.70
8.4.80.0100.00917.66
8.4.70.0170.00717.79
8.4.60.0130.00717.63
8.4.50.0090.00720.43
8.4.40.0030.00519.13
8.4.30.0130.00720.26
8.4.20.0140.00718.60
8.4.10.0090.00619.14
8.3.300.0100.01120.66
8.3.290.0110.01020.71
8.3.280.0130.01218.38
8.3.270.0110.00816.85
8.3.260.0130.00616.57
8.3.250.0110.00818.97
8.3.240.0110.00717.27
8.3.230.0140.00516.50
8.3.220.0050.00417.34
8.3.210.0110.00916.50
8.3.200.0080.00716.55
8.3.190.0030.00517.08
8.3.180.0110.00718.78
8.3.170.0120.00619.11
8.3.160.0070.00718.21
8.3.150.0030.01718.96
8.3.140.0110.00720.53
8.3.130.0060.00318.52
8.3.120.0090.00618.88
8.3.110.0050.00316.41
8.3.100.0070.00316.50
8.3.90.0000.00826.77
8.3.80.0030.00619.36
8.3.70.0110.00316.75
8.3.60.0090.00918.43
8.3.50.0100.00817.33
8.3.40.0100.01018.68
8.3.30.0140.00018.41
8.3.20.0000.00721.82
8.3.10.0030.00619.03
8.3.00.0050.00221.53
8.2.300.0120.00821.93
8.2.290.0130.00620.39
8.2.280.0130.00616.47
8.2.270.0080.01216.57
8.2.260.0150.00419.05
8.2.250.0100.00316.50
8.2.240.0080.00016.46
8.2.230.0060.00320.94
8.2.220.0060.00624.06
8.2.210.0000.00726.77
8.2.200.0050.00518.88
8.2.190.0120.00616.58
8.2.180.0120.00625.92
8.2.170.0120.00322.96
8.2.160.0120.00320.64
8.2.150.0000.00924.18
8.2.140.0090.00024.66
8.2.130.0030.01026.16
8.2.120.0070.00020.88
8.2.110.0100.00019.39
8.2.100.0080.00317.72
8.2.90.0000.00817.91
8.2.80.0040.00418.09
8.2.70.0080.00017.63
8.2.60.0070.00018.09
8.2.50.0080.00019.38
8.2.40.0000.00720.55
8.2.30.0020.00520.42
8.2.20.0060.00318.02
8.2.10.0000.00718.80
8.2.00.0000.00718.23
8.1.340.0110.00817.41
8.1.330.0120.00821.73
8.1.320.0110.00815.97
8.1.310.0130.00316.51
8.1.300.0040.00418.62
8.1.290.0090.00030.84
8.1.280.0140.00025.92
8.1.270.0030.00622.52
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0030.00622.19
8.1.230.0040.00820.85
8.1.220.0000.00817.78
8.1.210.0080.00018.89
8.1.200.0040.00417.23
8.1.190.0080.00017.23
8.1.180.0060.00318.10
8.1.170.0040.00418.64
8.1.160.0000.00718.86
8.1.150.0000.00718.87
8.1.140.0050.00220.12
8.1.130.0030.00620.30
8.1.120.0080.00017.46
8.1.110.0000.01017.50
8.1.100.0030.00617.27
8.1.90.0030.00517.49
8.1.80.0040.00417.46
8.1.70.0040.00417.35
8.1.60.0030.00617.63
8.1.50.0000.00817.54
8.1.40.0030.00617.39
8.1.30.0040.00417.66
8.1.20.0000.00817.66
8.1.10.0000.00717.52
8.1.00.0000.00717.42
8.0.300.0070.00019.95
8.0.290.0040.00416.75
8.0.280.0040.00418.43
8.0.270.0030.00517.22
8.0.260.0060.00018.53
8.0.250.0040.00416.93
8.0.240.0000.00816.93
8.0.230.0070.00016.86
8.0.220.0030.00616.88
8.0.210.0030.00316.79
8.0.200.0000.00716.86
8.0.190.0060.00316.93
8.0.180.0000.00716.79
8.0.170.0000.00816.76
8.0.160.0040.00416.88
8.0.150.0000.00816.72
8.0.140.0030.00316.79
8.0.130.0030.00313.38
8.0.120.0040.00416.83
8.0.110.0000.00816.82
8.0.100.0040.00416.89
8.0.90.0030.00316.76
8.0.80.0050.01016.90
8.0.70.0070.00016.87
8.0.60.0040.00416.89
8.0.50.0040.00416.75
8.0.30.0110.00617.21
8.0.20.0110.00817.11
8.0.10.0040.00416.95
8.0.00.0070.01416.63
7.4.330.0000.00515.55
7.4.320.0000.00616.48
7.4.300.0000.00716.59
7.4.290.0050.00316.56
7.4.280.0000.00716.53
7.4.270.0030.00316.50
7.4.260.0000.00716.46
7.4.250.0030.00316.39
7.4.240.0000.00716.54
7.4.230.0070.00016.32
7.4.220.0030.00616.61
7.4.210.0100.00616.60
7.4.200.0040.00416.38
7.4.160.0080.00816.60
7.4.140.0090.00917.86
7.4.130.0110.00816.58
7.4.120.0100.00716.62
7.4.110.0070.01016.61
7.4.100.0070.01416.51
7.4.90.0100.00616.54
7.4.80.0030.01419.39
7.4.70.0000.01716.31
7.4.60.0100.00616.42
7.4.50.0070.00716.32
7.4.40.0040.01216.32
7.4.00.0100.00714.73
7.3.330.0000.00513.13
7.3.320.0030.00313.04
7.3.310.0030.00316.12
7.3.300.0040.00416.18
7.3.290.0070.00716.17
7.3.280.0080.00816.13
7.3.260.0080.00916.33
7.3.230.0090.00916.20
7.3.210.0100.00716.19
7.3.200.0070.01116.65
7.3.190.0110.01016.36
7.3.180.0150.00416.48
7.3.170.0150.00616.25
7.3.160.0060.01116.50
7.3.50.0120.00914.60
7.3.40.0060.00914.63
7.3.30.0000.01214.72
7.3.20.0070.01116.33
7.3.10.0070.00716.75
7.3.00.0070.00716.64
7.2.330.0090.01516.72
7.2.320.0000.01716.44
7.2.310.0120.00616.35
7.2.300.0080.00816.20
7.2.290.0060.01016.74
7.2.180.0120.00314.84
7.2.170.0110.01115.01
7.2.160.0120.00414.77
7.2.150.0000.01516.86
7.2.140.0150.00017.11
7.2.130.0090.00616.84
7.2.120.0060.01116.81
7.2.110.0120.00916.86
7.2.100.0090.00616.93
7.2.90.0060.00616.93
7.2.80.0070.00416.91
7.2.70.0090.01216.87
7.2.60.0090.01317.05
7.2.50.0190.00316.96
7.2.40.0070.01416.82
7.2.30.0000.01416.96
7.2.20.0150.00716.95
7.2.10.0120.00617.07
7.2.00.0070.00716.52
7.1.280.0100.01015.59
7.1.270.0030.01015.88
7.1.260.0110.00315.79
7.1.250.0060.00815.75

preferences:
114.87 ms | 1402 KiB | 5 Q