let [|H;W;A;B|] = stdin.ReadLine().Split() |> Array.map int
let rec f h w =
    if h=H then ()
    elif w=W then
        stdout.WriteLine ""
        f (h+1) 0
    elif (h<H-B && w<W-A) || (h>H-B-1 && w>W-A-1) then
        stdout.Write 1
        f h (w+1)
    else
        stdout.Write 0
        f h (w+1)
f 0 0