import java.io.*; import java.util.*; public class Main_yukicoder725 { private static Scanner sc; private static Printer pr; private static void solve() { String s = sc.next(); int n = s.length(); int i = 0; int next; while ((next = s.indexOf("treeone", i)) >= 0) { for (int j = i; j < next; j++) { pr.print(s.charAt(j)); } pr.print("forest"); i = next + 7; } for (int j = i; j < n; j++) { pr.print(s.charAt(j)); } pr.println(); } // --------------------------------------------------- public static void main(String[] args) { sc = new Scanner(INPUT == null ? System.in : new ByteArrayInputStream(INPUT.getBytes())); pr = new Printer(System.out); solve(); // pr.close(); pr.flush(); // sc.close(); } static String INPUT = null; private static class Printer extends PrintWriter { Printer(OutputStream out) { super(out); } } }