S=input() while S: if "treeone" in S: x=S.index("treeone") S=S[:x]+"forest"+S[x+7:] else: break print(S)