OR63 删除公共字符
OR63 删除公共字符
import java.util.Scanner;import java.io.*;// 注意类名必须为 Main, 不要有任何 package xxx 信息
public class Main {public static void main(String[] args) throws IOException{BufferedReader br =new BufferedReader(new InputStreamReader(System.in));String c = br.readLine();String c2 = br.readLine();boolean[] hash = new boolean[250];for(int i = 0; i < c2.length();i++) {hash[c2.charAt(i)] = true;}StringBuffer s = new StringBuffer();for(int j = 0 ;j < c.length();j++) {if(!hash[c.charAt(j)]) {s.append(c.charAt(j));}}System.out.print(s);}
}