Re: regular expressions



<2rajesh.b@xxxxxxxxx> wrote in message news:1145883055.318877.19040@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
The password is at least six characters long.

The password contains characters from at least three of the following
five categories:
· English uppercase characters (A - Z)
· English lowercase characters (a - z)
· Base 10 digits (0 - 9)
· Non-alphanumeric (for example: !, $, #, or %)
· Unicode characters

can u please help me in writing a regular expression for the above
condition

All of categories are mutually exclusive except for "Unicode characters". And any character that you can get in memory via a program written in Java is a "unicode character", so that last category seems pretty redundant. Perhaps you mean something like a character within Unicode, but outside of ASCII?

I'm asking you for clarification because it sounds like the above requirements were not dreamt up by you, and so you should in turn be asking whoever assigned you with this task for clarification.

- Oliver

.



Relevant Pages

  • Re: regular expressions
    ... be able to do your own homework. ... The password is at least six characters long. ... · English uppercase characters ...
    (comp.lang.java.programmer)
  • Re: set up password change regularly with certain rules
    ... passwords should consist of 6 to 8 characters including one or more ... · lower case alphabetics ... So it looks to me that the default is to enforce complexity. ... in modern linux distros log-in password configuration is ...
    (Ubuntu)
  • Re: Unwanted Control Characters
    ... If you mean symbols that look like these: ¶? ... · as well as others they are ... hidden characters that don't print. ... Word doesn't use any type of "control characters" other than these. ...
    (microsoft.public.mac.office.word)
  • Re: Xterm & Unicode
    ... If I invoke "uxterm &", then I get a terminal by which Unicode characters ... an old Mac OS 9 program called NewsWatcher-X. ...
    (comp.os.linux.x)
  • Re: convert unicode characters to visibly similar ascii characters
    ... I want to convert unicode character into ascii one. ... The method ".encode" can convert only those unicode characters, ... only found that there exists Unicode database, ...
    (comp.lang.python)