import sys
from collections import Counter
for line in sys.stdin:
d=Counter(line.strip())
l=list(line.strip())
min_count=min(d.values())
for i in range(len(l)):
if d[l[i]]== min_count:
l[i]=''
print(''.join(l))