3v4l.org

run code in 300+ PHP versions simultaneously
<?php $city = 'Monterrey' return (preg_match('/^(Guadalajara|Monterrey|Puebla)$/i', $city) && $age >= 18);

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)
5.6.90.0100.06721.09
5.6.80.0170.07020.42
5.5.250.0130.05320.62
5.5.240.0270.06720.18
5.4.410.0070.05719.00
5.4.400.0770.00018.90
5.4.390.0770.00018.49
5.4.380.0800.00018.69
5.4.370.0730.00018.57
5.4.360.0770.00018.63
5.4.350.0800.00018.62
5.4.340.0770.00018.71
5.4.320.0800.00018.73
5.4.310.0800.00018.78
5.4.300.0870.00018.60
5.4.290.0800.00018.57
5.4.280.0970.00018.73
5.4.270.1000.00018.80
5.4.260.0900.00018.61
5.4.250.0800.00018.73
5.4.240.0800.00018.48
5.4.230.0770.00018.79
5.4.220.0830.00018.76
5.4.210.0800.00018.70
5.4.200.0770.00016.60
5.4.190.0730.00018.60
5.4.180.0770.00018.47
5.4.170.0830.00018.69
5.4.160.0770.00018.72
5.4.150.0730.00018.62
5.4.140.0770.00016.26
5.4.130.0700.00016.32
5.4.120.0730.00016.22
5.4.110.0770.00016.25
5.4.100.0730.00016.23
5.4.90.0700.00016.30
5.4.80.0700.00016.42
5.4.70.0730.00016.31
5.4.60.0730.00016.22
5.4.50.0700.00016.38
5.4.40.0730.00016.20
5.4.30.0730.00016.16
5.4.20.0870.00016.13
5.4.10.0670.00016.13
5.4.00.0730.00015.76
5.3.290.0830.00014.77
5.3.280.0770.00014.63
5.3.270.0800.00014.63
5.3.260.0770.00014.61
5.3.250.0770.00014.54
5.3.240.0770.00014.71
5.3.230.0730.00014.49
5.3.220.0830.00014.49
5.3.210.0770.00014.55
5.3.200.0700.00014.64
5.3.190.0630.00014.50
5.3.180.0770.00014.54
5.3.170.0870.00014.54
5.3.160.1230.00014.46
5.3.150.0870.00014.57
5.3.140.1000.00014.54
5.3.130.1100.00014.64
5.3.120.0800.00014.46
5.3.110.0830.00014.45
5.3.100.0770.00014.02
5.3.90.0800.00013.93
5.3.80.0800.00014.04
5.3.70.0730.00013.99
5.3.60.0770.00013.99
5.3.50.0770.00013.90
5.3.40.0930.00013.94
5.3.30.0730.00013.84
5.3.20.0770.00013.79
5.3.10.0830.00013.57
5.3.00.0770.00013.73
5.2.170.0670.00011.12
5.2.160.0630.00011.07
5.2.150.0630.00011.09
5.2.140.0600.00011.17
5.2.130.0630.00011.09
5.2.120.0570.00011.14
5.2.110.0800.00011.06
5.2.100.0600.00011.16
5.2.90.0630.00011.08
5.2.80.0630.00011.07
5.2.70.0570.00011.14
5.2.60.0630.00010.97
5.2.50.0630.00011.04
5.2.40.0630.00011.13
5.2.30.0600.00010.97
5.2.20.0500.00011.00
5.2.10.0500.00011.01
5.2.00.0470.00010.75
5.1.60.0500.00010.11
5.1.50.0500.00010.10
5.1.40.0500.00010.00
5.1.30.0470.00010.43
5.1.20.0700.00010.42
5.1.10.0700.00010.06
5.1.00.0530.00010.09
5.0.50.0370.0008.57
5.0.40.0370.0008.47
5.0.30.0600.0008.22
5.0.20.0330.0008.18
5.0.10.0400.0008.16
5.0.00.0530.0008.27
4.4.90.0330.0006.19
4.4.80.0300.0006.19
4.4.70.0330.0006.19
4.4.60.0270.0006.19
4.4.50.0270.0006.19
4.4.40.0430.0006.19
4.4.30.0330.0006.19
4.4.20.0270.0006.19
4.4.10.0270.0006.19
4.4.00.0400.0006.19
4.3.110.0270.0006.19
4.3.100.0300.0006.19
4.3.90.0300.0006.19
4.3.80.0400.0006.19
4.3.70.0300.0006.19
4.3.60.0300.0006.19
4.3.50.0300.0006.19
4.3.40.0470.0006.19
4.3.30.0270.0006.19
4.3.20.0270.0006.19
4.3.10.0230.0006.19
4.3.00.0100.0176.67

preferences:
135.44 ms | 1398 KiB | 7 Q