特殊字符前面加斜线的代码
char[] specialChars = {'(',')','*','.'}; String test = "()*."; String result = ""; char temp; boolean isExist = false; for (int i = 0; i < test.length(); i++) { temp = test.charAt(i); isExist = false; for (int j = 0; j < specialChars.length; j++) { if (temp == specialChars[j]) { isExist = tr
用户评论
晕,白下载了,就是简介那几行java代码