Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

Java Regex : 4 Letters followed by 2 Integers

public static boolean checkPass(String s){
    System.out.println(s); // Prints : Mypass85
    p = Pattern.compile("[A-Za-z]{4}[0-9]{2}");
    return p.matcher(s).find();
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Java #Regex #Letters #Integers
ADD COMMENT
Topic
Name
3+1 =