저는 해쉬를 이용해서 풀어보았습니다. import java.util.*; public class N1764 { public static void main(String[] args) { Scanner kb = new Scanner(System.in); int n = kb.nextInt(); int m = kb.nextInt(); String[] a = new String[n]; String[] b = new String[m]; for (int i = 0; i < n; i++) { a[i] = kb.next(); } for (int i = 0; i < m; i++) { b[i] = kb.next(); } for (String x : solution(a, b)) { System.out.println(x); }..