摘要: 1用JAVA自带的函数publicstaticbooleanisNumeric(Stringstr){for(inti=str.length();--i>=0;){if(!Character.isDigit(str.charAt(i))){returnfalse;}}returntrue;}2用正则表达式public static boolean isNumeric(String str){... 阅读全文
posted @ 2009-07-07 19:00 jdonson 阅读(467) 评论(0) 推荐(0) 编辑