3v4l.org

run code in 300+ PHP versions simultaneously
<?php $email = 'categoryparameterusedpricing_15'; $domain = strstr($email, '_', true); echo $domain.'<br>'; // выводит @example.com $user = strstr($email, '_'); // Начиная с PHP 5.3.0 echo str_replace('_','',$user); // выводит name

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.0160.00318.18
8.3.50.0090.01021.93
8.3.40.0080.00818.60
8.3.30.0070.00718.88
8.3.20.0080.00020.09
8.3.10.0100.00323.65
8.3.00.0040.00420.54
8.2.180.0080.00818.05
8.2.170.0080.00822.96
8.2.160.0070.00719.52
8.2.150.0040.00424.18
8.2.140.0000.00824.66
8.2.130.0040.00426.16
8.2.120.0000.01018.04
8.2.110.0000.00920.43
8.2.100.0090.00317.55
8.2.90.0040.00417.50
8.2.80.0030.00517.97
8.2.70.0030.00617.93
8.2.60.0050.00318.03
8.2.50.0030.00618.10
8.2.40.0000.00719.27
8.2.30.0060.00319.15
8.2.20.0000.00817.66
8.2.10.0070.00018.21
8.2.00.0050.00317.61
8.1.280.0070.01025.92
8.1.270.0000.00818.87
8.1.260.0070.00026.35
8.1.250.0040.00428.09
8.1.240.0100.00023.75
8.1.230.0120.00319.09
8.1.220.0030.00617.78
8.1.210.0000.00918.77
8.1.200.0000.00817.22
8.1.190.0080.00017.23
8.1.180.0030.00618.10
8.1.170.0030.00618.66
8.1.160.0000.00719.05
8.1.150.0040.00418.72
8.1.140.0000.00717.30
8.1.130.0000.00717.71
8.1.120.0000.00817.42
8.1.110.0080.00017.36
8.1.100.0030.00317.39
8.1.90.0040.00417.34
8.1.80.0000.00817.35
8.1.70.0030.00317.32
8.1.60.0030.00617.45
8.1.50.0050.00317.44
8.1.40.0000.00917.47
8.1.30.0030.00517.51
8.1.20.0050.00317.53
8.1.10.0000.00717.50
8.1.00.0000.00817.54
8.0.300.0040.00419.65
8.0.290.0050.00316.63
8.0.280.0030.00318.35
8.0.270.0030.00317.24
8.0.260.0030.00317.25
8.0.250.0000.00716.90
8.0.240.0030.00316.81
8.0.230.0000.00716.82
8.0.220.0030.00316.95
8.0.210.0070.00016.77
8.0.200.0030.00316.90
8.0.190.0000.00716.84
8.0.180.0070.00016.80
8.0.170.0050.00216.93
8.0.160.0080.00016.89
8.0.150.0070.00016.89
8.0.140.0000.00716.81
8.0.130.0060.00013.29
8.0.120.0030.00616.86
8.0.110.0000.00816.74
8.0.100.0000.00816.99
8.0.90.0000.00816.85
8.0.80.0000.01416.87
8.0.70.0050.00316.75
8.0.60.0000.00716.77
8.0.50.0070.00016.86
8.0.30.0110.00817.20
8.0.20.0100.00817.40
8.0.10.0070.00017.00
8.0.00.0070.01116.69
7.4.330.0050.00015.03
7.4.320.0030.00316.34
7.4.300.0030.00316.57
7.4.290.0050.00316.57
7.4.280.0030.00516.41
7.4.270.0040.00416.43
7.4.260.0070.00416.42
7.4.250.0040.00416.45
7.4.240.0070.00016.47
7.4.230.0070.00016.47
7.4.220.0030.01516.55
7.4.210.0070.01316.50
7.4.200.0050.00216.42
7.4.160.0130.00316.51
7.4.150.0090.00917.40
7.4.140.0090.00917.86
7.4.130.0130.00616.47
7.4.120.0090.00916.48
7.4.110.0080.01216.32
7.4.100.0030.01716.38
7.4.90.0120.00816.29
7.4.80.0130.00919.39
7.4.70.0090.00916.35
7.4.60.0100.00616.47
7.4.50.0040.00416.25
7.4.40.0140.00316.28
7.4.30.0160.01016.42
7.4.00.0060.01014.96
7.3.330.0000.00512.93
7.3.320.0000.00513.11
7.3.310.0000.00616.27
7.3.300.0000.00616.20
7.3.290.0070.00716.16
7.3.280.0070.01016.22
7.3.270.0090.00917.40
7.3.260.0120.00616.46
7.3.250.0090.01016.34
7.3.240.0190.00616.30
7.3.230.0120.01216.39
7.3.210.0100.03316.24
7.3.200.0070.01119.39
7.3.190.0090.01216.28
7.3.180.0070.00716.48
7.3.170.0170.00016.32
7.3.160.0130.00316.30
7.2.330.0100.00716.70
7.2.320.0070.01316.63
7.2.310.0110.00616.55
7.2.300.0030.01316.42
7.2.290.0130.00316.45
7.2.00.0030.01019.45
7.1.100.0000.01018.07
7.1.70.0040.00817.14
7.1.60.0030.00919.22
7.1.50.0040.01816.93
7.1.00.0130.06722.36
7.0.200.0000.00716.61
7.0.140.0000.04021.92
7.0.60.0100.07319.94
7.0.50.0070.06017.77
7.0.40.0030.09019.84
7.0.30.0170.04020.20
7.0.20.0330.07320.04
7.0.10.0030.05020.03
7.0.00.0030.04719.99
5.6.280.0030.07320.98
5.6.210.0130.07320.62
5.6.200.0030.08318.12
5.6.190.0070.07320.44
5.6.180.0430.04720.57
5.6.170.0400.07320.48
5.6.160.0170.06720.44
5.6.150.0030.04018.10
5.6.140.0100.06718.10
5.6.130.0030.04018.12
5.6.120.0130.07720.98
5.6.110.0100.07321.11
5.6.100.0170.06321.13
5.6.90.0170.07020.94
5.6.80.0030.05720.41
5.5.350.0200.04720.27
5.5.340.0100.08017.99
5.5.330.0000.08320.37
5.5.320.0230.07320.28
5.5.310.0300.07720.33
5.5.300.0030.07718.00
5.5.290.0100.04317.91
5.5.280.0030.04020.76
5.5.270.0030.08720.65
5.5.260.0070.07720.79
5.5.250.0070.05720.58
5.5.240.0000.08020.16
5.4.450.0500.08719.45
5.4.440.0700.06019.54
5.4.430.0530.06719.48
5.4.420.0770.07319.47
5.4.410.0830.05019.00
5.4.400.0930.08319.12
5.4.390.0600.06018.82
5.4.380.0230.05718.63
5.4.370.0270.04718.61
5.4.360.0230.05018.59
5.4.350.0170.06018.46
5.4.340.0330.04018.52
5.4.320.0270.05318.56
5.4.310.0330.04318.72
5.4.300.0200.05318.46
5.4.290.0130.06318.69
5.4.280.0200.05318.59
5.4.270.0230.05018.66
5.4.260.0270.05018.58
5.4.250.0230.05318.59
5.4.240.0330.04718.63
5.4.230.0200.05318.55
5.4.220.0270.05018.59
5.4.210.0300.04718.54
5.4.200.0230.05016.40
5.4.190.0170.05718.69
5.4.180.0300.04718.50
5.4.170.0270.05018.69
5.4.160.0230.05018.66
5.4.150.0300.05018.73
5.4.140.0070.06316.36
5.4.130.0230.04316.25
5.4.120.0230.04716.22
5.4.110.0170.05316.29
5.4.100.0200.05016.08
5.4.90.0170.05316.05
5.4.80.0270.04716.11
5.4.70.0170.05716.33
5.4.60.0200.05016.17
5.4.50.0200.05016.19
5.4.40.0300.04716.28
5.4.30.0130.05716.09
5.4.20.0200.05016.21
5.4.10.0130.05316.31
5.4.00.0230.04315.68
5.3.290.0270.05014.66
5.3.280.0300.04314.58
5.3.270.0170.06014.50
5.3.260.0100.06314.51
5.3.250.0170.05314.51
5.3.240.0230.04714.67
5.3.230.0170.05714.69
5.3.220.0200.05314.64
5.3.210.0200.05314.54
5.3.200.0300.04714.53
5.3.190.0330.04014.55
5.3.180.0270.04314.65
5.3.170.0230.04714.50
5.3.160.0170.05714.61
5.3.150.0230.05014.56
5.3.140.0370.06014.63
5.3.130.0130.06314.63
5.3.120.0130.06314.61
5.3.110.0330.05714.54
5.3.100.0330.05014.02
5.3.90.0200.05013.95
5.3.80.0230.05714.00
5.3.70.0230.06713.95
5.3.60.0230.04713.95
5.3.50.0170.05013.93
5.3.40.0270.04313.91
5.3.30.0230.04313.82
5.3.20.0300.03713.78
5.3.10.0230.04313.61
5.3.00.0130.05313.71
5.2.170.0170.04011.10
5.2.160.0170.04711.17
5.2.150.0130.04311.10
5.2.140.0170.03711.10
5.2.130.0070.04711.07
5.2.120.0170.04011.24
5.2.110.0130.04011.16
5.2.100.0200.03311.14
5.2.90.0170.03711.14
5.2.80.0200.03711.01
5.2.70.0200.04311.02
5.2.60.0200.04011.01
5.2.50.0230.04010.93
5.2.40.0170.03710.92
5.2.30.0130.04311.01
5.2.20.0170.03710.96
5.2.10.0200.03310.87
5.2.00.0070.05010.69
5.1.60.0130.0379.99
5.1.50.0100.03710.06
5.1.40.0070.04010.03
5.1.30.0170.03310.36
5.1.20.0100.04310.45
5.1.10.0170.03310.13
5.1.00.0130.03710.09
5.0.50.0070.0308.57
5.0.40.0130.0238.52
5.0.30.0130.0408.23
5.0.20.0100.0308.21
5.0.10.0070.0308.24
5.0.00.0070.0438.14
4.4.90.0100.0207.09
4.4.80.0070.0237.09
4.4.70.0070.0207.09
4.4.60.0100.0177.09
4.4.50.0070.0237.09
4.4.40.0170.0277.09
4.4.30.0070.0237.09
4.4.20.0100.0207.09
4.4.10.0070.0237.09
4.4.00.0070.0337.09
4.3.110.0130.0177.09
4.3.100.0070.0207.09
4.3.90.0070.0207.09
4.3.80.0100.0307.09
4.3.70.0070.0207.09
4.3.60.0030.0237.09
4.3.50.0170.0137.09
4.3.40.0070.0337.09
4.3.30.0030.0237.09
4.3.20.0030.0237.09
4.3.10.0000.0277.09
4.3.00.0100.02710.29

preferences:
38.51 ms | 401 KiB | 5 Q