#include using namespace std; int main() { string S; cin >> S; string s = "treeone"; string t = "forest"; string ans; for( int i = 0; i < S.size(); i++ ) { if( S.substr( i, s.size() ) == s ) { ans += t; i += s.size() - 1; } else ans += S[i]; } cout << ans << endl; }