import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    }
} Main public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    } main {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    } Scanner sc=new Scanner(System.in); sc new Scanner(System.in) char c[]=sc.next().toCharArray(); c sc.next().toCharArray() sc.next().toCharArray sc.next() sc.next sc System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No") System.out.println System.out System System.out (c[2]==c[3]&&c[4]==c[5])?"Yes":"No" (c[2]==c[3]&&c[4]==c[5]) c[2]==c[3] c[2] c 2 c[3] c 3 c[4]==c[5] c[4] c 4 c[5] c 5 "Yes" "No" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        char c[]=sc.next().toCharArray();
        System.out.println((c[2]==c[3]&&c[4]==c[5])?"Yes":"No");
    }
}
