import java.util.*; public class Main{ public static void main(String[] args){ Scanner in = new Scanner(System.in); while(in.hasNext()){ String s1 = in.next(); String s2 = in.next(); Set<Character> set = new HashSet<>(); char[] arr1 = s1.toCharArray(); char[] arr2 = s2.toCharArray(); for (char c : arr1){ set.add(c); } for (char c : arr2){ if (set.contains(c)) set.remove(c); } System.out.println(set.size() == 0); } } }