S, T, K = input(), [], "" for C in S: if K != C: T.append(C) K = S print("".join(T))