#include #include #include int main() { //std::ifstream inf("Text.txt"); std::cin.rdbuf(inf.rdbuf()); std::string S; std::cin >> S; while (1) { if (S.find("treeone", 0) != std::string::npos) { S.replace(S.find("treeone", 0), 7, "forest"); } else { break; } } std::cout << S << std::endl; return 0; }