import java.io.*;
import java.util.*;

public class Main{
    public static void main(String[] args) throws Exception{
        Scanner sc = new Scanner(System.in);
        while(sc.hasNextLine()){
            String s = sc.nextLine();
            char[] cc = s.toCharArray();
            int[] count = new int[26];

            for(char c : cc){
                count[c - 'a'] += 1;
            }
            int minValue = Integer.MAX_VALUE;

            for(int i = 0; i < 26; ++i){
                if(count[i] != 0 && minValue > count[i]){
                    minValue = count[i];
                }
            }
            Set<Character> set = new HashSet<>();

            for(int i = 0; i < 26; ++i){
                if(count[i] == minValue){
                    set.add((char)('a' + i));
                }
            }
            for(char c : cc){
                if(!set.contains(c)){
                    System.out.print(c);
                }
            }

            System.out.println();
        }
    }
}