program plus_minus_rectangle
  implicit none
  integer :: h, w, x, y, a(500,500), i, j
  a = 0
  read(*,*) h, w, x, y
  if (mod(h,x).eq.0.and.mod(w,y).eq.0) then
    write(*,'(a)') "No"
    stop
  end if
  write(*,'(a)') "Yes"
  do i = 1, h, x
    do j = 1, w, y
      a(i,j) = 999999
      if (i+x-1.le.h.and.j+y-1.le.w) a(i+x-1,j+y-1) = -1000000
    end do
  end do
  do i = 1, h
    call output(a(i,1:w))
  end do
  stop
contains
  subroutine output(a)
    implicit none
    integer, intent(in) :: a(:)
    integer :: n, i
    n = size(a)
    do i = 1, n
      write(*,'(i0,x)',advance='no') a(i)
    end do
    write(*,*)
    return
  end subroutine output
end program plus_minus_rectangle