program prob44
    implicit none
    character(5) :: s
    integer :: i
    read(*,*) s
    do i = 1, 4
        if(s(i:i+1) == "AC") then
            write(*,*) "Yes"
            stop   
        end if
    end do
    write(*,*) "No"

    stop
contains
end program prob44