program main
  implicit none
  integer i, H, W, A, B
  character(1000) X1,X2
  read(*, *)H, W, A, B
  !allocate(X1(W))
  !allocate(X2(W))
  !read(*, *) (L(i), i = 1,N)
  do i = 1,A
    X1(i:i) = '1'
    X2(i:i) = '0'
  end do
  do i = A+1,W
    X1(i:i) = '0'
    X2(i:i) = '1'
  end do
  do i = 1,H
    if (i > B) then
      write(*, *) X2(1:W)
    else
      write(*, *) X1(1:W)
    end if
  end do
end program main
