A=list(input()) B=list(input()) A.sort() B.sort() i=0 while i