java.util.regex.PatternSyntaxException: Unclosed counted closure near index 14

java.util.regex.PatternSyntaxException: Unclosed counted closure near index 14


  错误:  request.getParameter("username");
        Pattern p = Pattern.compile("^[0-9A-Za-z]{1-10}");

    正确:request.getParameter("username");
        Pattern p = Pattern.compile("^[0-9A-Za-z]{1,10}");

你可能感兴趣的:(java.util.regex.PatternSyntaxException: Unclosed counted closure near index 14)