import re
str = input()

# 去掉”#“之后的
index = str.find("#")
str = str[0:index]
print(str)

# 去掉”-“
str = re.sub("-", "", str)
print(str)