3v4l.org

run code in 300+ PHP versions simultaneously
<?php $pswd = "1SZ1@1"; $letterStart = preg_match("/^[A-Za-z]/", $pswd); // start with a letter $specialChar= preg_match("/(?=.*[!@#&*%]+)/", $pswd); // one or more special chars in list $numberChar= preg_match("/(?=.*[\d]{2,})/", $pswd); //two or more digits x $upperChar= preg_match("/(?=.*[A-Z]\w{2,})/", $pswd); //two or more upper case letters $lowerChar= preg_match("/(?=.*[a-z]\w{2,})/", $pswd); //two or more lower case letters $pswdLength = preg_match("/(?=^.{6,20}$)/", $pswd); //length of pswd between min and max echo $letterStart . " " . $specialChar . " " . $numberChar . " " . $upperChar . " " . $lowerChar . " " . $pswdLength;

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.0120.01218.55
8.3.50.0110.00822.27
8.3.40.0040.01118.96
8.3.30.0130.00718.82
8.3.20.0040.00420.23
8.3.10.0080.00021.60
8.3.00.0050.00319.51
8.2.180.0070.00718.38
8.2.170.0110.00722.96
8.2.160.0100.00320.22
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0000.00822.28
8.2.110.0060.00321.30
8.2.100.0040.00818.03
8.2.90.0080.00018.16
8.2.80.0040.00418.22
8.2.70.0000.00818.04
8.2.60.0040.00417.63
8.2.50.0090.00018.10
8.2.40.0000.00720.46
8.2.30.0000.00819.38
8.2.20.0040.00417.99
8.2.10.0040.00418.00
8.2.00.0000.00818.04
8.1.280.0040.01125.92
8.1.270.0030.00622.16
8.1.260.0000.00726.35
8.1.250.0000.00728.09
8.1.240.0060.00322.42
8.1.230.0040.00821.10
8.1.220.0030.00617.91
8.1.210.0050.00518.80
8.1.200.0050.00317.61
8.1.190.0030.00617.48
8.1.180.0030.00618.10
8.1.170.0080.00020.62
8.1.160.0040.00418.93
8.1.150.0000.00818.95
8.1.140.0030.00617.65
8.1.130.0030.00317.79
8.1.120.0030.00417.62
8.1.110.0040.00417.68
8.1.100.0050.00217.66
8.1.90.0040.00717.70
8.1.80.0000.00917.55
8.1.70.0070.00017.58
8.1.60.0040.00417.73
8.1.50.0040.00417.67
8.1.40.0050.00317.58
8.1.30.0050.00317.73
8.1.20.0050.00317.77
8.1.10.0040.00417.58
8.1.00.0080.00017.59
8.0.300.0060.00319.98
8.0.290.0000.00717.00
8.0.280.0030.00518.50
8.0.270.0000.00717.31
8.0.260.0070.00017.30
8.0.250.0070.00017.09
8.0.240.0070.00017.16
8.0.230.0030.00317.08
8.0.220.0030.00517.11
8.0.210.0030.00517.10
8.0.200.0000.00617.24
8.0.190.0000.01117.09
8.0.180.0040.00417.17
8.0.170.0050.00317.04
8.0.160.0000.00717.14
8.0.150.0070.00017.10
8.0.140.0040.00417.10
8.0.130.0000.00713.65
8.0.120.0080.00017.09
8.0.110.0000.00817.07
8.0.100.0030.00516.93
8.0.90.0020.00516.94
8.0.80.0070.00717.02
8.0.70.0000.00717.13
8.0.60.0070.00017.12
8.0.50.0000.00717.00
8.0.30.0100.01517.17
8.0.20.0130.00717.49
8.0.10.0040.00417.05
8.0.00.0050.01316.90
7.4.330.0020.00215.12
7.4.320.0030.00316.86
7.4.300.0030.00316.82
7.4.290.0000.00716.79
7.4.280.0080.00016.73
7.4.270.0040.00416.90
7.4.260.0030.00316.73
7.4.250.0000.00816.85
7.4.240.0000.00816.79
7.4.230.0000.00716.87
7.4.220.0090.00916.80
7.4.210.0040.01116.74
7.4.200.0040.00416.81
7.4.160.0080.00816.61
7.4.150.0130.00317.40
7.4.140.0120.01017.86
7.4.130.0060.01216.73
7.4.120.0070.01116.77
7.4.110.0160.00716.61
7.4.100.0150.00316.71
7.4.90.0120.00616.56
7.4.80.0100.01319.39
7.4.70.0100.00716.82
7.4.60.0030.01316.68
7.4.50.0030.00516.74
7.4.40.0030.01316.65
7.4.30.0080.00816.73
7.4.00.0170.00015.07
7.3.330.0000.00513.33
7.3.320.0060.00013.26
7.3.310.0030.00616.44
7.3.300.0000.00716.52
7.3.290.0070.01116.51
7.3.280.0080.00916.52
7.3.270.0100.01017.40
7.3.260.0100.00716.37
7.3.250.0140.00816.64
7.3.240.0090.00916.79
7.3.230.0100.00716.50
7.3.210.0130.00316.77
7.3.200.0130.01019.39
7.3.190.0110.00616.78
7.3.180.0000.01516.64
7.3.170.0000.01716.56
7.3.160.0150.00616.42
7.3.10.0000.01416.57
7.3.00.0190.00316.61
7.2.330.0120.00616.64
7.2.320.0090.00916.96
7.2.310.0030.01316.60
7.2.300.0030.01316.86
7.2.290.0130.01016.88
7.2.130.0120.00417.13
7.2.120.0150.00016.94
7.2.110.0040.01716.34
7.2.100.0110.00317.02
7.2.90.0180.00416.81
7.2.80.0090.00916.86
7.2.70.0050.01017.21
7.2.60.0080.00817.07
7.2.50.0150.01116.98
7.2.40.0080.01316.93
7.2.30.0130.01016.86
7.2.20.0070.01016.87
7.2.10.0070.01017.01
7.2.00.0040.01016.84
7.1.250.0100.00715.26
7.1.200.0030.00315.87
7.1.70.0040.00417.49
7.1.60.0100.01319.11
7.1.50.0100.01317.05
7.1.00.0030.07322.52
7.0.200.0040.00416.98
7.0.140.0030.07322.01
7.0.60.0030.08719.92
7.0.50.0170.07017.81
7.0.40.0070.06020.11
7.0.30.0330.07320.15
7.0.20.0400.07020.18
7.0.10.0030.08720.11
7.0.00.0070.09020.22
5.6.280.0000.07721.09
5.6.210.0100.08020.76
5.6.200.0070.07718.22
5.6.190.0100.03720.67
5.6.180.0330.04020.57
5.6.170.1030.03720.44
5.6.160.0070.07720.44
5.6.150.0100.06718.09
5.6.140.0070.06318.15
5.6.130.0070.07718.16
5.6.120.0100.06020.82
5.6.110.0100.08021.13
5.6.100.0070.08321.13
5.6.90.0070.06720.95
5.6.80.0070.03720.39
5.5.350.0200.07720.32
5.5.340.0100.08018.02
5.5.330.0030.05020.21
5.5.320.0270.06720.18
5.5.310.0300.08320.27
5.5.300.0000.04017.90
5.5.290.0070.03717.95
5.5.280.0000.05020.68
5.5.270.0000.06020.95
5.5.260.0070.07020.77
5.5.250.0070.08320.54
5.5.240.0300.06320.26
5.4.450.0030.06719.64
5.4.440.0500.05719.46
5.4.430.0700.05319.43
5.4.420.0670.00019.50
5.4.410.0630.00019.19
5.4.400.0630.00019.23
5.4.390.0670.00018.99
5.4.380.0700.00019.06
5.4.370.0630.00019.05
5.4.360.0630.00018.95
5.4.350.0670.00019.11
5.4.340.0070.03511.97
5.4.320.0070.05212.46
5.4.310.0040.04312.45
5.4.300.0040.03812.46
5.4.290.0070.03912.45
5.4.280.0100.03412.35
5.4.270.0050.04112.35
5.4.260.0060.04812.35
5.4.250.0060.04612.35
5.4.240.0050.03712.35
5.4.230.0050.03912.34
5.4.220.0030.03912.34
5.4.210.0070.03512.34
5.4.200.0100.03412.34
5.4.190.0070.03712.34
5.4.180.0050.03912.34
5.4.170.0030.04012.35
5.4.160.0070.03612.35
5.4.150.0050.03612.34
5.4.140.0070.03512.03
5.4.130.0060.03612.01
5.4.120.0050.03611.97
5.4.110.0070.03411.96
5.4.100.0080.03211.97
5.4.90.0060.03611.96
5.4.80.0080.03311.97
5.4.70.0110.03111.96
5.4.60.0060.03411.96
5.4.50.0060.03411.96
5.4.40.0020.04011.95
5.4.30.0120.03411.95
5.4.20.0070.03911.95
5.4.10.0050.03711.95
5.4.00.0050.03811.44
5.3.290.0080.03912.80
5.3.280.0050.04412.71
5.3.270.0060.04412.72
5.3.260.0110.03512.72
5.3.250.0050.03912.72
5.3.240.0050.04312.72
5.3.230.0070.04012.70
5.3.220.0050.03912.68
5.3.210.0070.03712.68
5.3.200.0070.03612.68
5.3.190.0060.03712.68
5.3.180.0090.03512.68
5.3.170.0030.04012.67
5.3.160.0050.03812.67
5.3.150.0050.04212.68
5.3.140.0090.03412.66
5.3.130.0030.04312.66
5.3.120.0080.03912.66
5.3.110.0040.04012.66
5.3.100.0110.04112.12
5.3.90.0070.04112.08
5.3.80.0080.03512.08
5.3.70.0060.04512.07
5.3.60.0080.05012.06
5.3.50.0070.04212.00
5.3.40.0080.03512.00
5.3.30.0070.03511.95
5.3.20.0090.03211.73
5.3.10.0060.03411.70
5.3.00.0090.03411.69
5.2.170.0060.0299.19
5.2.160.0060.0439.19
5.2.150.0060.0339.19
5.2.140.0030.0409.19
5.2.130.0080.0309.15
5.2.120.0080.0339.14
5.2.110.0060.0329.16
5.2.100.0100.0349.14
5.2.90.0070.0409.15
5.2.80.0050.0339.14
5.2.70.0060.0329.14
5.2.60.0050.0379.10
5.2.50.0030.0359.07
5.2.40.0050.0359.05
5.2.30.0050.0319.03
5.2.20.0060.0299.02
5.2.10.0120.0248.94
5.2.00.0070.0308.80
5.1.60.0040.0258.08
5.1.50.0060.0238.07
5.1.40.0040.0308.05
5.1.30.0030.0288.41
5.1.20.0060.0258.43
5.1.10.0060.0258.15
5.1.00.0040.0268.15
5.0.50.0030.0216.64
5.0.40.0040.0206.51
5.0.30.0030.0326.32
5.0.20.0060.0216.28
5.0.10.0070.0206.27
5.0.00.0030.0336.26
4.4.90.0040.0194.78
4.4.80.0020.0204.76
4.4.70.0050.0164.76
4.4.60.0040.0144.76
4.4.50.0040.0164.77
4.4.40.0040.0244.71
4.4.30.0010.0174.76
4.4.20.0050.0134.84
4.4.10.0000.0184.85
4.4.00.0010.0264.76
4.3.110.0040.0174.67
4.3.100.0030.0144.67
4.3.90.0050.0164.64
4.3.80.0040.0244.58
4.3.70.0030.0154.63
4.3.60.0050.0144.63
4.3.50.0030.0184.63
4.3.40.0020.0274.54
4.3.30.0020.0183.30
4.3.20.0030.0153.28
4.3.10.0030.0153.23
4.3.00.0070.0207.48

preferences:
54.59 ms | 401 KiB | 5 Q