#include using namespace std; int main(){ cin.tie(0),ios::sync_with_stdio(false); string s; cin>>s; string t="treeone"s,f="forest"s; auto pos=s.find(t); while(pos!=string::npos){ s=s.substr(0,pos)+f+s.substr(pos+t.size()); pos=s.find(t,pos+f.size()); } cout<