总长度小于60
^d{6}[wdu4e00-u9fa5]{1,54}$
后面部分长度小于60
^d{6}[wdu4e00-u9fa5]{1,60}$
能帮忙讲讲吗?我在java项目里,不能用呀?我不会用正则
如果你只要匹配,直接用String的match方法就行了。如果要更复杂,比如提取匹配的内容,可以使用Pattern类
match("111111fdsfsdf电风扇");}publicstaticvoidmatch(Stringstr){System.out.println(str.matches("^d{6}[wdu4e00-u9fa5]{1,54}$“))报错,输出语句里面,双引号里面的正则报错