java源代码如下:
package test;
public class DotMain {
public static void main(String... args) {
String s1 = "abcdex";
String s2 = "ac";
boolean[] r1 = new boolean[26];
for (char c : s1.toCharArray())
r1[c - 'a'] = true;
boolean contained = true;
for (char c : s2.toCharArray()) {
if (!r1[c - 'a']) {
contained = false;
break;
}
}
System.out.println(contained);
System.out.println(s1 + s2);
}
}
如果没有“包测试”;相应的类文件将表现正确。但是当我添加“包测试;” 发生了标题中所述的异常。有什么不对?