3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = 'http://www.azlyrics.com/a/abba.html'; $pos = strpos($str, '.html'); $get = substr($str, 0, $pos); echo $get; $pos2 = strpos($get, '/'); $get2 = substr($get, $pos2, '-1'); echo $get2;

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.0040.01118.31
8.3.50.0110.00416.37
8.3.40.0120.00318.58
8.3.30.0070.00718.54
8.3.20.0050.00223.65
8.3.10.0080.00021.86
8.3.00.0080.00019.38
8.2.180.0100.01018.02
8.2.170.0070.00722.96
8.2.160.0160.00322.19
8.2.150.0020.00524.18
8.2.140.0000.00724.66
8.2.130.0000.00918.09
8.2.120.0000.00726.35
8.2.110.0100.00019.27
8.2.100.0110.00018.03
8.2.90.0030.00517.75
8.2.80.0030.00618.70
8.2.70.0030.00517.80
8.2.60.0090.00017.79
8.2.50.0100.00018.10
8.2.40.0000.00720.65
8.2.30.0030.00619.31
8.2.20.0000.00718.06
8.2.10.0070.00018.05
8.2.00.0040.00417.78
8.1.280.0120.00325.92
8.1.270.0080.00020.31
8.1.260.0000.00726.35
8.1.250.0060.00328.09
8.1.240.0120.00920.30
8.1.230.0110.00018.87
8.1.220.0000.00817.77
8.1.210.0080.00018.77
8.1.200.0030.00617.23
8.1.190.0060.00317.23
8.1.180.0070.00018.10
8.1.170.0000.00720.12
8.1.160.0040.00418.81
8.1.150.0040.00420.16
8.1.140.0000.00719.54
8.1.130.0030.00318.99
8.1.120.0000.00717.40
8.1.110.0070.00017.35
8.1.100.0070.00017.43
8.1.90.0000.00717.39
8.1.80.0040.00417.24
8.1.70.0030.00317.40
8.1.60.0000.00817.34
8.1.50.0070.00017.38
8.1.40.0000.00717.46
8.1.30.0040.00417.65
8.1.20.0040.00417.54
8.1.10.0040.00417.48
8.1.00.0080.00017.39
8.0.300.0050.00218.77
8.0.290.0050.00316.63
8.0.280.0070.00018.34
8.0.270.0070.00017.25
8.0.260.0050.00317.29
8.0.250.0030.00316.82
8.0.240.0000.00816.95
8.0.230.0000.00716.87
8.0.220.0040.00416.72
8.0.210.0040.00416.86
8.0.200.0050.00316.75
8.0.190.0000.00816.76
8.0.180.0030.00516.77
8.0.170.0000.00716.87
8.0.160.0000.00816.80
8.0.150.0000.00716.75
8.0.140.0000.00716.75
8.0.130.0000.01013.26
8.0.120.0050.00316.81
8.0.110.0040.00416.71
8.0.100.0050.00316.60
8.0.90.0000.00716.71
8.0.80.0090.00616.85
8.0.70.0040.00416.71
8.0.60.0000.00716.82
8.0.50.0040.00416.94
8.0.30.0110.01016.95
8.0.20.0100.00817.40
8.0.10.0040.00416.78
8.0.00.0130.00316.66
7.4.330.0050.00015.55
7.4.320.0030.00316.56
7.4.300.0060.00016.53
7.4.290.0020.00416.55
7.4.280.0000.01016.47
7.4.270.0000.00716.44
7.4.260.0030.00316.42
7.4.250.0040.00416.25
7.4.240.0070.00016.58
7.4.230.0030.00616.27
7.4.220.0130.01016.56
7.4.210.0110.00516.46
7.4.200.0030.00316.44
7.4.160.0120.00316.46
7.4.150.0060.01117.40
7.4.140.0100.00817.86
7.4.130.0070.01116.49
7.4.120.0100.00816.38
7.4.110.0070.01116.46
7.4.100.0090.00816.54
7.4.90.0070.01016.52
7.4.80.0150.00319.39
7.4.70.0130.00316.39
7.4.60.0100.00616.29
7.4.50.0100.00616.58
7.4.40.0030.01316.57
7.4.30.0080.01416.52
7.4.00.0040.01115.02
7.3.330.0000.00613.05
7.3.320.0000.00613.04
7.3.310.0000.00716.04
7.3.300.0030.00316.19
7.3.290.0000.00716.03
7.3.280.0080.00916.20
7.3.270.0150.00417.40
7.3.260.0110.00816.39
7.3.250.0130.00716.25
7.3.240.0150.00516.45
7.3.230.0140.00316.22
7.3.210.0030.01316.58
7.3.200.0060.00919.39
7.3.190.0140.01516.10
7.3.180.0120.00616.27
7.3.170.0120.00616.31
7.3.160.0130.00316.23
7.2.330.0080.01116.45
7.2.320.0030.01316.65
7.2.310.0120.00916.40
7.2.300.0140.00416.52
7.2.290.0060.00916.39
7.1.200.0000.01215.59
7.1.70.0030.00816.95
7.1.60.0040.00817.29
7.1.10.0100.05722.42
7.1.00.0100.05322.61
7.0.200.0030.01316.73
7.0.140.0100.05722.12
7.0.130.0030.05721.97
7.0.120.0000.06021.97
7.0.110.0130.05022.09
7.0.100.0100.05322.16
7.0.90.0170.06722.15
7.0.80.0070.05721.96
7.0.70.0070.05722.12
7.0.60.0070.05721.95
7.0.50.0070.05722.09
7.0.40.0170.04722.17
7.0.30.0100.05322.20
7.0.20.0100.05322.04
7.0.10.0030.06022.04
7.0.00.0070.05721.97

preferences:
30.76 ms | 401 KiB | 5 Q