import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner input = new Scanner(System.in); String str = input.nextLine(); int num= str.length(); Boolean first = false; if(num%8!=0) { System.out.print("Wrong Format"); } else { for(int i=0;i<num;i++) { String stus = str.substring(i,i+8); i=i+7; if(stus.startsWith("202017")||stus.startsWith("202061")) { String ok = stus.substring(4,8); if(first==true) System.out.print(" "+ok); else System.out.print(ok); first=true; } } } } }