3v4l.org

run code in 300+ PHP versions simultaneously
<?php function reverse($str) { if (strlen($str) < 2) { return $str; } println($str[0]); return reverse(substr($str, 1)) . $str[0]; } $txt = "Thomas"; echo reverse($txt);

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.0100.01016.50
8.3.50.0080.00818.16
8.3.40.0110.00418.84
8.3.30.0070.01118.67
8.3.20.0040.00420.34
8.3.10.0040.00423.53
8.3.00.0090.00019.38
8.2.180.0000.01518.38
8.2.170.0140.00322.96
8.2.160.0110.00420.42
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0060.00617.63
8.2.120.0050.00326.35
8.2.110.0060.00322.23
8.2.100.0000.01217.91
8.2.90.0080.00019.09
8.2.80.0090.00017.97
8.2.70.0040.00417.50
8.2.60.0080.00017.55
8.2.50.0050.00318.07
8.2.40.0030.00619.53
8.2.30.0050.00220.54
8.2.20.0030.00617.62
8.2.10.0040.00418.00
8.2.00.0040.00418.09
8.1.280.0210.00025.92
8.1.270.0060.00324.02
8.1.260.0060.00328.09
8.1.250.0000.00728.09
8.1.240.0080.00023.82
8.1.230.0090.00318.90
8.1.220.0030.00517.76
8.1.210.0040.00418.77
8.1.200.0100.00017.35
8.1.190.0040.00717.23
8.1.180.0000.00818.10
8.1.170.0040.00418.78
8.1.160.0000.00721.99
8.1.150.0000.00718.70
8.1.140.0000.00919.43
8.1.130.0030.00317.64
8.1.120.0030.00317.34
8.1.110.0040.00417.42
8.1.100.0040.00417.41
8.1.90.0000.00717.28
8.1.80.0040.00417.37
8.1.70.0040.00417.26
8.1.60.0080.00017.59
8.1.50.0090.00317.58
8.1.40.0040.00417.49
8.1.30.0040.00417.60
8.1.20.0000.00717.54
8.1.10.0030.00617.59
8.1.00.0050.00317.44
8.0.300.0040.00418.77
8.0.290.0070.00016.75
8.0.280.0030.00318.36
8.0.270.0050.00317.08
8.0.260.0030.00317.18
8.0.250.0040.00416.87
8.0.240.0040.00416.87
8.0.230.0030.00316.93
8.0.220.0000.00716.87
8.0.210.0000.00716.77
8.0.200.0030.00616.88
8.0.190.0000.01016.99
8.0.180.0000.00816.82
8.0.170.0040.00416.80
8.0.160.0030.00516.88
8.0.150.0000.00716.93
8.0.140.0030.00316.89
8.0.130.0050.00013.30
8.0.120.0050.00316.75
8.0.110.0040.00416.81
8.0.100.0030.00516.88
8.0.90.0040.00416.68
8.0.80.0000.01416.85
8.0.70.0000.00716.88
8.0.60.0070.00016.74
8.0.50.0000.00716.74
8.0.30.0120.00617.24
8.0.20.0090.01217.40
8.0.10.0050.00216.79
8.0.00.0120.00816.74
7.4.330.0050.00016.75
7.4.320.0030.00316.56
7.4.300.0000.00716.41
7.4.290.0070.00016.50
7.4.280.0000.00716.52
7.4.270.0030.00316.43
7.4.260.0070.00016.49
7.4.250.0000.00716.36
7.4.240.0060.00216.53
7.4.230.0030.00316.67
7.4.220.0220.00616.58
7.4.210.0040.01816.55
7.4.200.0070.00016.39
7.4.160.0120.00916.54
7.4.150.0120.01217.40
7.4.140.0110.00817.86
7.4.130.0150.00416.66
7.4.120.0050.01216.56
7.4.110.0090.00916.64
7.4.100.0040.01616.32
7.4.90.0060.01216.51
7.4.80.0120.00919.39
7.4.70.0070.01416.55
7.4.60.0100.00716.44
7.4.50.0030.01416.41
7.4.40.0070.01016.66
7.4.30.0050.01016.36
7.4.00.0050.01214.94
7.3.330.0020.00213.43
7.3.320.0060.00013.19
7.3.310.0030.00316.38
7.3.300.0040.00416.31
7.3.290.0060.00916.38
7.3.280.0060.00916.33
7.3.270.0130.00417.40
7.3.260.0070.01016.55
7.3.250.0150.01016.51
7.3.240.0090.00816.51
7.3.230.0150.00316.50
7.3.210.0120.00516.34
7.3.200.0070.01016.35
7.3.190.0070.01116.63
7.3.180.0080.00816.30
7.3.170.0030.01516.45
7.3.160.0090.00616.49
7.3.120.0130.00614.79
7.3.110.0070.01314.82
7.3.100.0130.00315.00
7.3.90.0080.00414.57
7.3.80.0040.00814.96
7.3.70.0080.00314.90
7.3.60.0090.00614.91
7.3.50.0040.00814.97
7.3.40.0090.00614.85
7.3.30.0060.00314.71
7.3.20.0070.00716.74
7.3.10.0040.01116.88
7.3.00.0030.01016.72
7.2.330.0000.01616.74
7.2.320.0100.00616.30
7.2.310.0110.00616.51
7.2.300.0110.01516.39
7.2.290.0060.01116.51
7.2.250.0150.00414.78
7.2.240.0070.01014.86
7.2.230.0080.00915.10
7.2.220.0100.00314.93
7.2.210.0060.01015.18
7.2.200.0130.00014.87
7.2.190.0100.00314.96
7.2.180.0090.00614.95
7.2.170.0070.00315.08
7.2.60.0100.00316.90
7.2.00.0080.00819.34
7.1.330.0000.01215.83
7.1.320.0060.00315.48
7.1.310.0030.01015.75
7.1.300.0030.00715.39
7.1.290.0060.01015.69
7.1.280.0030.00615.81
7.1.270.0030.01015.85
7.1.260.0060.00315.63
7.1.200.0060.00615.77
7.1.100.0060.00917.85
7.1.70.0070.01317.01
7.1.60.0000.01619.36
7.1.50.0100.00316.55
7.1.00.0070.07322.37
7.0.200.0030.00616.62
7.0.60.0030.04019.96
7.0.50.0100.06317.85
7.0.40.0130.07320.27
7.0.30.0270.04320.08
7.0.20.0270.08020.07
7.0.10.0100.07320.07
7.0.00.0000.04720.06
5.6.280.0000.07321.10
5.6.210.0100.08720.61
5.6.200.0170.05718.18
5.6.190.0100.06720.48
5.6.180.0300.04320.46
5.6.170.0200.04720.47
5.6.160.0030.04320.39
5.6.150.0130.07718.16
5.6.140.0100.06018.14
5.6.130.0070.05718.27
5.6.120.0170.06721.02
5.6.110.0100.08021.02
5.6.100.0070.07321.07
5.6.90.0030.04320.93
5.6.80.0030.04320.38
5.5.350.2500.04320.47
5.5.340.0070.04018.08
5.5.330.0030.04720.27
5.5.320.0070.07320.36
5.5.310.0400.07020.14
5.5.300.0100.07718.08
5.5.290.0130.05717.95
5.5.280.0100.07320.84
5.5.270.0070.07720.73
5.5.260.0070.08020.89
5.5.250.0130.07320.71
5.5.240.0300.06720.16

preferences:
40.83 ms | 400 KiB | 5 Q