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

arow = '1'*A + '0'*(W-A)
brow = '0'*A + '1'*(W-A)

for i in range(1,H+1):
    if (i <= B):
        print(brow)
    else:
        print(arow) H, W, A, B = map(int, input().split()) H map(int, input().split()) map int input().split() ().split () input split W A B arow = '1'*A + '0'*(W-A) arow '1'*A + '0'*(W-A) '1'*A '1' A '0'*(W-A) '0' W-A W A brow = '0'*A + '1'*(W-A) brow '0'*A + '1'*(W-A) '0'*A '0' A '1'*(W-A) '1' W-A W A for i in range(1,H+1):
    if (i <= B):
        print(brow)
    else:
        print(arow) i range(1,H+1) range 1 H+1 H 1 if (i <= B):
        print(brow)
    else:
        print(arow) i <= B i B print(brow) print brow print(arow) print arow W, A, B = map(int, input().split()) map(int, input().split()) W B = map(int, input().split()) map(int, input().split()) B arow = '1'*A + '0'*(W-A) '1'*A + '0'*(W-A) arow H, W, A, B = map(int, input().split()) map(int, input().split()) H A, B = map(int, input().split()) map(int, input().split()) A brow = '0'*A + '1'*(W-A) '0'*A + '1'*(W-A) brow
H, W, A, B = map(int, input().split())

arow = '1'*A + '0'*(W-A)
brow = '0'*A + '1'*(W-A)

for i in range(1,H+1):
    if (i <= B):
        print(brow)
    else:
        print(arow)