3v4l.org

run code in 300+ PHP versions simultaneously
<?php $pswd = "A1Q1@pa"; $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+/", $pswd); //two or more digits x $upperChar= preg_match("/(?=.*[A-Z]\w\S{2,})/", $pswd); //two or more upper case letters $lowerChar= preg_match("/(?=.*[a-z]\w\S{2,})/", $pswd); //two or more lower case letters x $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.0060.00916.59
8.3.50.0090.01121.21
8.3.40.0070.01018.84
8.3.30.0160.00619.00
8.3.20.0060.00320.39
8.3.10.0040.00423.48
8.3.00.0030.00519.38
8.2.180.0040.01116.75
8.2.170.0040.01122.96
8.2.160.0100.00320.53
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0100.00322.18
8.2.110.0060.00320.39
8.2.100.0090.00317.84
8.2.90.0040.00419.21
8.2.80.0000.00817.97
8.2.70.0030.00617.61
8.2.60.0070.00318.05
8.2.50.0060.00318.07
8.2.40.0080.00018.22
8.2.30.0070.00018.19
8.2.20.0040.00417.86
8.2.10.0040.00418.19
8.2.00.0000.00817.88
8.1.280.0150.00725.92
8.1.270.0000.00922.31
8.1.260.0050.00326.35
8.1.250.0050.00328.09
8.1.240.0000.01023.75
8.1.230.0090.00321.13
8.1.220.0080.00017.77
8.1.210.0030.00618.77
8.1.200.0060.00317.61
8.1.190.0000.00817.60
8.1.180.0020.00518.10
8.1.170.0050.00318.74
8.1.160.0040.00422.03
8.1.150.0050.00218.95
8.1.140.0040.00417.63
8.1.130.0060.00317.70
8.1.120.0030.00517.64
8.1.110.0000.00817.53
8.1.100.0000.00717.57
8.1.90.0100.00017.63
8.1.80.0000.00717.68
8.1.70.0070.00017.62
8.1.60.0060.00617.67
8.1.50.0080.00017.74
8.1.40.0030.00617.71
8.1.30.0030.00617.73
8.1.20.0040.00417.88
8.1.10.0030.00517.69
8.1.00.0060.00317.65
8.0.300.0040.00418.77
8.0.290.0070.00017.00
8.0.280.0030.00518.57
8.0.270.0030.00317.31
8.0.260.0070.00016.97
8.0.250.0000.00717.11
8.0.240.0000.00717.24
8.0.230.0000.00717.09
8.0.220.0000.00717.07
8.0.210.0050.00317.04
8.0.200.0030.00317.10
8.0.190.0040.00717.23
8.0.180.0020.00517.04
8.0.170.0050.00317.17
8.0.160.0000.00817.25
8.0.150.0040.00417.11
8.0.140.0070.00017.02
8.0.130.0030.00313.55
8.0.120.0000.00817.03
8.0.110.0040.00417.19
8.0.100.0020.00517.10
8.0.90.0040.00417.18
8.0.80.0070.01417.14
8.0.70.0040.00417.06
8.0.60.0040.00417.18
8.0.50.0000.00817.16
8.0.30.0110.01117.17
8.0.20.0140.01117.40
8.0.10.0030.00516.98
8.0.00.0080.01116.89
7.4.330.0000.00515.02
7.4.320.0060.00016.72
7.4.300.0040.00416.69
7.4.290.0050.00216.66
7.4.280.0060.00316.74
7.4.270.0030.00316.82
7.4.260.0000.00716.70
7.4.250.0000.00816.80
7.4.240.0060.00116.74
7.4.230.0030.00316.52
7.4.220.0110.01316.90
7.4.210.0040.01816.64
7.4.200.0000.00816.58
7.4.160.0040.01616.73
7.4.150.0180.00717.40
7.4.140.0120.01317.86
7.4.130.0140.00716.71
7.4.120.0110.00516.76
7.4.110.0090.00916.68
7.4.100.0090.00916.54
7.4.90.0070.01116.75
7.4.80.0070.01119.39
7.4.70.0120.00316.68
7.4.60.0120.00616.78
7.4.50.0030.00616.70
7.4.40.0060.01016.43
7.4.30.0100.00616.69
7.4.10.0110.00715.16
7.4.00.0070.01015.11
7.3.330.0000.00513.48
7.3.320.0050.00013.41
7.3.310.0070.00016.56
7.3.300.0070.00016.41
7.3.290.0060.01016.56
7.3.280.0090.01016.49
7.3.270.0080.01617.40
7.3.260.0130.00316.71
7.3.250.0110.00916.67
7.3.240.0060.01316.83
7.3.230.0120.00916.67
7.3.210.0110.00716.79
7.3.200.0170.00619.39
7.3.190.0100.00716.55
7.3.180.0060.00916.37
7.3.170.0130.00316.75
7.3.160.0090.00616.32
7.3.130.0090.00914.83
7.3.120.0030.01414.84
7.3.110.0110.00814.75
7.3.100.0020.01214.91
7.3.90.0080.00815.02
7.3.80.0050.01214.85
7.3.70.0030.00814.88
7.3.60.0070.00814.96
7.3.50.0100.00515.05
7.3.40.0070.00714.94
7.3.30.0050.00714.89
7.3.20.0060.00716.94
7.3.10.0030.01116.90
7.3.00.0020.01016.76
7.2.330.0070.01016.74
7.2.320.0080.00916.58
7.2.310.0070.01016.72
7.2.300.0100.00716.92
7.2.290.0120.00616.83
7.2.260.0100.01015.43
7.2.250.0080.00915.22
7.2.240.0060.01215.05
7.2.230.0100.00815.07
7.2.220.0050.00915.14
7.2.210.0070.00715.28
7.2.200.0060.00615.32
7.2.190.0100.00315.15
7.2.180.0020.01215.23
7.2.170.0090.00515.13
7.2.160.0040.01115.22
7.2.150.0060.00616.97
7.2.140.0000.01017.07
7.2.130.0030.01217.07
7.2.120.0040.01216.82
7.2.110.0120.00317.04
7.2.100.0060.00917.24
7.2.90.0100.00717.17
7.2.80.0060.00617.10
7.2.70.0030.00917.08
7.2.60.0060.00916.88
7.2.50.0120.00317.29
7.2.40.0030.00917.15
7.2.30.0070.00717.34
7.2.20.0070.01117.15
7.2.10.0110.00416.91
7.2.00.0060.00917.00
7.1.330.0100.00515.88
7.1.320.0050.00715.90
7.1.310.0080.00815.65
7.1.300.0060.00815.83
7.1.290.0070.00515.82
7.1.280.0030.01015.91
7.1.270.0060.00815.78
7.1.260.0040.01015.76
7.1.250.0000.01215.84
7.1.240.0070.00315.98
7.1.230.0070.00716.07
7.1.220.0050.00515.60
7.1.210.0100.00315.63
7.1.200.0030.00515.68
7.1.190.0030.01015.78
7.1.180.0120.00316.15
7.1.170.0000.00915.57
7.1.160.0030.00716.02
7.1.150.0030.01016.04
7.1.140.0040.01116.11
7.1.130.0060.00615.72
7.1.120.0140.00015.98
7.1.110.0000.01516.08
7.1.100.0040.00716.09
7.1.90.0080.00415.76
7.1.80.0110.00315.82
7.1.70.0040.00616.38
7.1.60.0070.00917.61
7.1.50.0050.01016.63
7.1.40.0120.00315.94
7.1.30.0070.01015.86
7.1.20.0030.00616.00
7.1.10.0090.00315.93
7.1.00.0060.04019.17
7.0.330.0030.00715.35
7.0.320.0060.00615.67
7.0.310.0030.00915.35
7.0.300.0000.01315.73
7.0.290.0030.00715.48
7.0.280.0060.00915.20
7.0.270.0040.00415.45
7.0.260.0070.00715.75
7.0.250.0030.00715.63
7.0.240.0070.00315.82
7.0.230.0030.01015.40
7.0.220.0030.01015.65
7.0.210.0030.00615.60
7.0.200.0020.01016.30
7.0.190.0080.00015.75
7.0.180.0030.01415.48
7.0.170.0040.01115.50
7.0.160.0070.00415.25
7.0.150.0070.00715.59
7.0.140.0070.04018.83
7.0.130.0000.01515.47
7.0.120.0060.00615.46
7.0.110.0080.00515.33
7.0.100.0110.00415.56
7.0.90.0110.00015.65
7.0.80.0090.00615.61
7.0.70.0030.01015.73
7.0.60.0070.04217.65
7.0.50.0080.03716.79
7.0.40.0050.02716.90
7.0.30.0200.03817.01
7.0.20.0140.04616.81
7.0.10.0030.02816.90
7.0.00.0050.02816.96
5.6.400.0030.00914.31
5.6.390.0060.00314.43
5.6.380.0000.00814.34
5.6.370.0030.00614.56
5.6.360.0030.00614.46
5.6.350.0030.01014.37
5.6.340.0000.01714.34
5.6.330.0040.00714.19
5.6.320.0030.00914.44
5.6.310.0060.00614.36
5.6.300.0030.01014.17
5.6.290.0040.01114.30
5.6.280.0100.03717.74
5.6.270.0030.01014.37
5.6.260.0070.00714.66
5.6.250.0060.00314.37
5.6.240.0060.00814.47
5.6.230.0110.00314.16
5.6.220.0070.00314.72
5.6.210.0070.02317.48
5.6.200.0050.04716.17
5.6.190.0050.02517.38
5.6.180.0200.03817.70
5.6.170.0630.03117.26
5.6.160.0070.02217.32
5.6.150.0130.03316.29
5.6.140.0020.03016.24
5.6.130.0070.04216.30
5.6.120.0060.02317.53
5.6.110.0080.04117.60
5.6.100.0080.02917.55
5.6.90.0060.02417.68
5.6.80.0010.02417.24
5.6.70.0120.00614.36
5.6.60.0000.01314.11
5.6.50.0100.00314.17
5.6.40.0080.00314.41
5.6.30.0100.00314.61
5.6.20.0000.01714.31
5.6.10.0070.01014.38
5.6.00.0060.00614.18
5.5.380.0030.00914.39
5.5.370.0070.00714.46
5.5.360.0070.00314.19
5.5.350.0130.03817.40
5.5.340.0100.04016.01
5.5.330.0030.02717.10
5.5.320.0200.04117.14
5.5.310.0120.04217.13
5.5.300.0060.02216.24
5.5.290.0070.02716.06
5.5.280.0110.04217.54
5.5.270.0130.03717.47
5.5.260.0020.02817.57
5.5.250.0050.03617.36
5.5.240.0230.03317.19
5.5.230.0030.01414.06
5.5.220.0080.00513.83
5.5.210.0150.00014.41
5.5.200.0050.00313.96
5.5.190.0090.00613.85
5.5.180.0070.01114.03
5.5.170.0070.00714.36
5.5.160.0040.01114.29
5.5.150.0030.01214.27
5.5.140.0040.01114.14
5.5.130.0080.00314.38
5.5.120.0070.00714.31
5.5.110.0110.00413.99
5.5.100.0040.00813.98
5.5.90.0030.01014.25
5.5.80.0090.00314.09
5.5.70.0070.01014.26
5.5.60.0030.00913.87
5.5.50.0090.00614.38
5.5.40.0040.00814.02
5.5.30.0000.01214.25
5.5.20.0030.01014.32
5.5.10.0040.00413.92
5.5.00.0030.00614.03
5.4.450.0370.03615.60
5.4.440.0550.02915.47
5.4.430.0580.02815.58
5.4.420.0350.00415.56
5.4.410.0320.00515.43
5.4.400.0310.00415.46
5.4.390.0340.00315.41
5.4.380.0370.00515.38
5.4.370.0320.00315.43
5.4.360.0320.00415.34
5.4.350.0350.00415.43
5.4.340.0060.02111.84
5.4.330.0060.00011.71
5.4.320.0050.02112.08
5.4.310.0080.02512.08
5.4.300.0050.02312.08
5.4.290.0040.02112.08
5.4.280.0050.02212.03
5.4.270.0040.02812.03
5.4.260.0040.03212.03
5.4.250.0050.02412.03
5.4.240.0040.02212.03
5.4.230.0060.02212.03
5.4.220.0060.02012.03
5.4.210.0030.02312.03
5.4.200.0040.02312.03
5.4.190.0050.02112.02
5.4.180.0070.01812.02
5.4.170.0040.02012.03
5.4.160.0060.02112.03
5.4.150.0030.02212.02
5.4.140.0020.02211.87
5.4.130.0080.01711.86
5.4.120.0070.01811.84
5.4.110.0030.02411.84
5.4.100.0030.02211.84
5.4.90.0050.02211.84
5.4.80.0050.02211.84
5.4.70.0060.02011.83
5.4.60.0030.02211.83
5.4.50.0070.01911.84
5.4.40.0040.02011.83
5.4.30.0050.02111.83
5.4.20.0070.01811.83
5.4.10.0040.02111.83
5.4.00.0080.02111.57
5.3.290.0100.04712.80
5.3.280.0070.03812.71
5.3.270.0040.04212.73
5.3.260.0070.03912.72
5.3.250.0070.03812.72
5.3.240.0070.03612.72
5.3.230.0070.03612.71
5.3.220.0130.03012.68
5.3.210.0080.03612.68
5.3.200.0050.03712.68
5.3.190.0060.03812.68
5.3.180.0060.03712.68
5.3.170.0070.03612.67
5.3.160.0080.03712.67
5.3.150.0050.03912.67
5.3.140.0060.03712.66
5.3.130.0050.04012.66
5.3.120.0070.03812.66
5.3.110.0100.03512.66
5.3.100.0070.03512.12
5.3.90.0060.03712.09
5.3.80.0070.04012.08
5.3.70.0050.03712.08
5.3.60.0040.03812.06
5.3.50.0060.03512.00
5.3.40.0060.04312.00
5.3.30.0090.03411.96
5.3.20.0090.04611.74
5.3.10.0060.04511.70
5.3.00.0040.03711.69
5.2.170.0020.0329.19
5.2.160.0060.0329.18
5.2.150.0050.0329.19
5.2.140.0030.0319.18
5.2.130.0030.0309.14
5.2.120.0050.0289.14
5.2.110.0040.0309.15
5.2.100.0030.0389.15
5.2.90.0050.0379.15
5.2.80.0050.0379.15
5.2.70.0030.0319.14
5.2.60.0010.0359.11
5.2.50.0050.0329.07
5.2.40.0050.0289.06
5.2.30.0040.0319.03
5.2.20.0060.0289.02
5.2.10.0080.0328.93
5.2.00.0040.0308.80
5.1.60.0040.0248.08
5.1.50.0030.0278.07
5.1.40.0040.0248.05
5.1.30.0060.0348.41
5.1.20.0050.0288.43
5.1.10.0030.0278.16
5.1.00.0050.0248.15
5.0.50.0020.0216.64
5.0.40.0020.0206.51
5.0.30.0030.0316.31
5.0.20.0050.0186.29
5.0.10.0030.0226.26
5.0.00.0040.0306.25
4.4.90.0030.0154.78
4.4.80.0020.0164.76
4.4.70.0020.0194.75
4.4.60.0040.0144.76
4.4.50.0020.0174.77
4.4.40.0040.0254.71
4.4.30.0030.0164.76
4.4.20.0020.0174.84
4.4.10.0040.0154.84
4.4.00.0060.0224.76
4.3.110.0030.0164.67
4.3.100.0030.0154.66
4.3.90.0030.0154.63
4.3.80.0070.0204.58
4.3.70.0030.0154.63
4.3.60.0010.0174.62
4.3.50.0050.0154.63
4.3.40.0010.0284.54
4.3.30.0030.0183.30
4.3.20.0030.0213.28
4.3.10.0010.0183.23
4.3.00.0130.0237.56

preferences:
39.89 ms | 401 KiB | 5 Q