String regx = "[^a|b|3]";
String temp = "6sabcsssfsfs33";
Pattern p = Pattern.compile(regx);
Matcher m = p.matcher(temp);
while (m.find()) {
System.out.print(m.group());
}
假如有字符串“6sabcsssfsfs33” ,用最有快速的方法去掉字符“ab3”,不能用java内置字符串方法(indeOf,substring,replaceAll等)?
最新推荐文章于 2024-07-22 14:15:06 发布