H,W,A,B = map(int,input().split())

C = [1]*(W-A) + [0]*A
D = [0]*(W-A) + [1]*A
c = ''
d = ''
for i in C:
    c += str(i)
c = int(c)
for i in D:
    d += str(i)
d = d.zfill(W)

for i in range(H):
    if i < H-B:
        print(c)
    else:
        print(d) H,W,A,B = map(int,input().split()) H map(int,input().split()) map int input().split() ().split () input split W A B C = [1]*(W-A) + [0]*A C [1]*(W-A) + [0]*A [1]*(W-A) [1] 1 W-A W A [0]*A [0] 0 A D = [0]*(W-A) + [1]*A D [0]*(W-A) + [1]*A [0]*(W-A) [0] 0 W-A W A [1]*A [1] 1 A c = '' c '' d = '' d '' for i in C:
    c += str(i) i C c += str(i) c str(i) str i c = int(c) c int(c) int c for i in D:
    d += str(i) i D d += str(i) d str(i) str i d = d.zfill(W) d d.zfill(W) d.zfill d zfill W for i in range(H):
    if i < H-B:
        print(c)
    else:
        print(d) i range(H) range H if i < H-B:
        print(c)
    else:
        print(d) i < H-B i H-B H B print(c) print c print(d) print d W,A,B = map(int,input().split()) map(int,input().split()) W c += str(i) str(i) c d += str(i) str(i) d H,W,A,B = map(int,input().split()) map(int,input().split()) H B = map(int,input().split()) map(int,input().split()) B d = '' '' d c = int(c) int(c) c A,B = map(int,input().split()) map(int,input().split()) A D = [0]*(W-A) + [1]*A [0]*(W-A) + [1]*A D C = [1]*(W-A) + [0]*A [1]*(W-A) + [0]*A C c = '' '' c d = d.zfill(W) d.zfill(W) d
H,W,A,B = map(int,input().split())

C = [1]*(W-A) + [0]*A
D = [0]*(W-A) + [1]*A
c = ''
d = ''
for i in C:
    c += str(i)
c = int(c)
for i in D:
    d += str(i)
d = d.zfill(W)

for i in range(H):
    if i < H-B:
        print(c)
    else:
        print(d)