s=input() ans="" for i in s: if k==0: if i=="#": k=1 else: if i=="#": k=0 else: ans+=i print(ans)