import java.io.*; import java.util.Arrays; public class No69 { public static void main(String[] args) { try(BufferedReader input = new BufferedReader(new InputStreamReader(System.in))){ String A= input.readLine(); String B= input.readLine(); char H_A[] =new char[10]; char H_B[] =new char[10]; boolean unmatch=false; if(A.equals(B)) System.out.println("YES"); else{ H_A=A.toCharArray(); Arrays.sort(H_A); H_B=B.toCharArray(); Arrays.sort(H_B); for(int i=0;i