h,w,a,b = map(int,input().split())
ans = [''] * h
for i in range(h):
  if i < b :
    ans[i] = '0'*a + '1'*(w-a)
  else:
    ans[i] = '1'*a + '0'*(w-a)
for s in ans:
  print(s) h,w,a,b = map(int,input().split()) h map(int,input().split()) map int input().split() ().split () input split w a b ans = [''] * h ans [''] * h [''] '' h for i in range(h):
  if i < b :
    ans[i] = '0'*a + '1'*(w-a)
  else:
    ans[i] = '1'*a + '0'*(w-a) i range(h) range h if i < b :
    ans[i] = '0'*a + '1'*(w-a)
  else:
    ans[i] = '1'*a + '0'*(w-a) i < b i b ans[i] = '0'*a + '1'*(w-a) ans[i] ans i '0'*a + '1'*(w-a) '0'*a '0' a '1'*(w-a) '1' w-a w a ans[i] = '1'*a + '0'*(w-a) ans[i] ans i '1'*a + '0'*(w-a) '1'*a '1' a '0'*(w-a) '0' w-a w a for s in ans:
  print(s) s ans print(s) print s w,a,b = map(int,input().split()) map(int,input().split()) w a,b = map(int,input().split()) map(int,input().split()) a h,w,a,b = map(int,input().split()) map(int,input().split()) h ans = [''] * h [''] * h ans b = map(int,input().split()) map(int,input().split()) b
h,w,a,b = map(int,input().split())
ans = [''] * h
for i in range(h):
  if i < b :
    ans[i] = '0'*a + '1'*(w-a)
  else:
    ans[i] = '1'*a + '0'*(w-a)
for s in ans:
  print(s)
