while 1: r,*a='/'*9 for c in input():a[r.count(c)]+=c;r=''.join(a).strip('/') print(r)