3v4l.org

run code in 300+ PHP versions simultaneously
<?php function get_numerics ($str) { preg_match('/^mom_(\d+)$/', $str, $matches); return $matches[1]; } $one = 'mom_5'; $two = 'mom_123'; $three = 'actions'; print_r(get_numerics($one)); print_r(get_numerics($two)); print_r(get_numerics($three));

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.0140.00416.88
8.3.50.0090.00616.67
8.3.40.0120.00318.96
8.3.30.0120.00618.72
8.3.20.0040.00420.21
8.3.10.0070.00021.73
8.3.00.0070.00418.03
8.2.180.0110.00318.78
8.2.170.0070.00722.96
8.2.160.0170.00320.52
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0080.00021.07
8.2.120.0030.00526.35
8.2.110.0060.00620.95
8.2.100.0080.00418.09
8.2.90.0050.00319.05
8.2.80.0000.00817.97
8.2.70.0030.00617.75
8.2.60.0050.00217.93
8.2.50.0060.00318.10
8.2.40.0040.00420.42
8.2.30.0030.00520.93
8.2.20.0040.00417.97
8.2.10.0000.00817.95
8.2.00.0040.00418.03
8.1.280.0100.00725.92
8.1.270.0050.00222.19
8.1.260.0000.00826.35
8.1.250.0000.00728.09
8.1.240.0090.00024.01
8.1.230.0040.00719.21
8.1.220.0080.00017.74
8.1.210.0000.00818.77
8.1.200.0060.00317.23
8.1.190.0050.00317.35
8.1.180.0030.00618.10
8.1.170.0000.00920.41
8.1.160.0060.00319.09
8.1.150.0040.00420.56
8.1.140.0000.00719.49
8.1.130.0030.00318.91
8.1.120.0040.00417.59
8.1.110.0040.00417.59
8.1.100.0030.00617.62
8.1.90.0060.00617.48
8.1.80.0040.00417.56
8.1.70.0000.00717.54
8.1.60.0030.00517.64
8.1.50.0080.00017.70
8.1.40.0000.00817.55
8.1.30.0000.00717.72
8.1.20.0070.00017.71
8.1.10.0030.00517.71
8.1.00.0040.00417.69
8.0.300.0020.00518.77
8.0.290.0000.00716.58
8.0.280.0030.00318.46
8.0.270.0030.00317.15
8.0.260.0040.00416.97
8.0.250.0070.00017.01
8.0.240.0030.00417.13
8.0.230.0040.00417.09
8.0.220.0050.00316.93
8.0.210.0030.00316.98
8.0.200.0000.00817.09
8.0.190.0000.00817.01
8.0.180.0070.00016.95
8.0.170.0000.00816.95
8.0.160.0040.00416.94
8.0.150.0000.00717.03
8.0.140.0000.00717.01
8.0.130.0060.00013.47
8.0.120.0000.00717.05
8.0.110.0030.00316.94
8.0.100.0040.00417.06
8.0.90.0000.00717.08
8.0.80.0080.00817.02
8.0.70.0080.00017.01
8.0.60.0040.00417.12
8.0.50.0000.00717.03
8.0.30.0100.00717.24
8.0.20.0100.01017.42
8.0.10.0000.00717.08
8.0.00.0060.01217.17
7.4.330.0060.00015.55
7.4.320.0030.00316.71
7.4.300.0070.00016.82
7.4.290.0060.00316.73
7.4.280.0080.00016.82
7.4.270.0040.00416.84
7.4.260.0030.00313.42
7.4.250.0050.00316.72
7.4.240.0030.00516.79
7.4.230.0000.00716.54
7.4.220.0070.01316.88
7.4.210.0050.01216.71
7.4.200.0030.00516.72
7.4.160.0110.00616.51
7.4.150.0150.00617.40
7.4.140.0110.00717.86
7.4.130.0090.00916.68
7.4.120.0110.01216.79
7.4.110.0130.00316.53
7.4.100.0170.00016.71
7.4.90.0080.01116.58
7.4.80.0070.01019.39
7.4.70.0070.01116.60
7.4.60.0080.00816.70
7.4.50.0110.00716.50
7.4.40.0170.00716.71
7.4.30.0120.00416.78
7.4.00.0000.00815.05
7.3.330.0000.00513.55
7.3.320.0000.00613.59
7.3.310.0060.00316.57
7.3.300.0030.00516.54
7.3.290.0040.00416.37
7.3.280.0210.01116.45
7.3.270.0090.00917.40
7.3.260.0160.00316.47
7.3.250.0090.00916.50
7.3.240.0040.01316.61
7.3.230.0140.00316.51
7.3.210.0070.01016.52
7.3.200.0110.00616.45
7.3.190.0160.00016.55
7.3.180.0120.00916.68
7.3.170.0150.00616.44
7.3.160.0160.00616.89
7.3.10.0180.01016.80
7.3.00.0250.00916.68
7.2.330.0130.00716.77
7.2.320.0080.00816.54
7.2.310.0100.01016.66
7.2.300.0030.01416.61
7.2.290.0100.00716.74
7.2.130.0180.00617.08
7.2.120.0200.01216.86
7.2.110.0230.00517.02
7.2.100.0170.01117.10
7.2.90.0220.00617.03
7.2.80.0190.01016.72
7.2.70.0350.00016.91
7.2.60.0080.01417.00
7.2.50.0190.01916.84
7.2.40.0110.02217.13
7.2.30.0280.00817.14
7.2.20.0160.01616.98
7.2.10.0240.01017.09
7.2.00.0090.00917.94
7.1.250.0200.00715.93
7.1.200.0040.00815.86
7.1.100.0030.00718.68
7.1.70.0050.00817.27
7.1.60.0170.01335.30
7.1.50.0230.00635.11
7.1.40.0230.00434.60
7.1.30.0240.01735.00
7.1.20.0200.00734.72
7.1.10.0040.00916.98
7.1.00.0040.01117.06
7.0.200.0030.01016.79
7.0.190.0070.00717.11
7.0.180.0100.00316.28
7.0.170.0030.01016.37
7.0.160.0030.01016.36
7.0.150.0060.00616.40
7.0.140.0090.00316.66
7.0.130.0080.00516.71
7.0.120.0070.00716.43
7.0.110.0030.00916.41
7.0.100.0060.00616.35
7.0.90.0070.00716.22
7.0.80.0000.01316.23
7.0.70.0040.00816.57
7.0.60.0040.00916.41
7.0.50.0070.00716.42
7.0.40.0030.00916.66
7.0.30.0040.00816.57
7.0.20.0070.00716.45
7.0.10.0000.01316.45
7.0.00.0100.00316.44

preferences:
49.16 ms | 400 KiB | 5 Q