import java.util.Scanner;

/**
 * Main
 */
public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    }
} import java.util.Scanner; Scanner java.util public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    } main {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String coffee = "coffee"; coffee "coffee" int flag = 0; flag 0 String S = sc.next(); S sc.next() sc.next sc if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        } S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6)) S.substring(2,3).equals(S.substring(3,4)) S.substring(2,3).equals S.substring(2,3) S.substring S 2 3 S.substring(3,4) S.substring S 3 4 S.substring(4,5).equals(S.substring(5,6)) S.substring(4,5).equals S.substring(4,5) S.substring S 4 5 S.substring(5,6) S.substring S 5 6 {
        } {
            flag = 1;
        } flag = 1 flag 1 if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        } flag == 1 flag 1 {
            System.out.println("No");
        } System.out.println("No") System.out.println System.out System System.out "No" {
            System.out.println("Yes");
        } System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    }
} public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    }
} Main
import java.util.Scanner;

/**
 * Main
 */
public class Main {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String coffee = "coffee";
        int flag = 0;

        String S = sc.next();
        if(S.substring(2,3).equals(S.substring(3,4)) && S.substring(4,5).equals(S.substring(5,6))){
        }else{
            flag = 1;
        }
        if(flag == 1){
            System.out.println("No");
        }else{
            System.out.println("Yes");
        }
    }
}