A = list(raw_input()) B = list(raw_input()) for a in A: if a in B: B.remove(a) if len(B) == 0: print('YES') else: print('NO')