如何用正则判断一个字符串是否全是0
正则
------解决方案--------------------
^0+$,字数
------解决方案--------------------
public static void main(String[] args) {
String str = "0001";
boolean isNum = str.matches("[0]+");
System.out.println(isNum);
}