S=input()

X=""
t="*"
for s in S:
    if s!=t:
        X+=s
    t=s
print(X)