Help for this page

Select Code to Download


  1. or download this
    my @RE = (qr/[[:lower:]]/, qr/[[:upper:]]/, qr/[0-9]/, qr/[^[:alnum:]]
    +/);
    sub check {
    ...
        return if $length < 20 && (! /$RE[0]/ || ! /$RE[1]/);
        return 1
    }
    
  2. or download this
    use List::Util qw{ any };
    
    ...
        return if $length < 20 && any { $password !~ $RE[$_] } 0 .. 1;
        return 1
    }