while True:
    try:
        s = input()
        n = []
        dic = {}
        for i in s:
            n.append(s.count(i))
        i = 0
        for j in n:
            if j != min(n):	# n没有排序,所以,如果j最小,也意味着s中对应字母出现次数最小
                print(s[i],end='')
            i += 1
    except:
        break