let str;
while(str = readline()){
  let strArr = str.split('')
  getMin(str,strArr)
}

function getMin(str,strArr){
  let obj = {};
  for(let v of strArr){
    if(obj[v]){
      obj[v]++;
    }else{
      obj[v] = 1;
    }
  }

  //算出出现最少次数的数值是多少
  let minNum = 20; //因为最多也就只能出现20次
  for(let key in obj){
    if(obj[key] < minNum){
      minNum = obj[key];
    }
  }

  let res = strArr;
  for(let key in obj){
    if(obj[key] == minNum){
      res = res.filter((v)=>{
        return v!=key;
      })
    }
  }

  console.log(res.join(''))
}