{-# LANGUAGE OverloadedStrings #-}
import Control.Monad
import Data.Char
import Data.List
import Data.Maybe
import qualified Data.ByteString.Char8 as BS

main :: IO ()
main = do
  [h, w, a, b] <- getIntList
  let s = BS.replicate a '0' `BS.append` BS.replicate (w-a) '1'
  let s' = BS.replicate a '1' `BS.append` BS.replicate (w-a) '0'
  replicateM_ b $ BS.putStrLn s
  replicateM_ (h-b) $ BS.putStrLn s'

-- IO
readInt :: BS.ByteString -> Maybe (Int, BS.ByteString)
readInt = BS.readInt . BS.dropWhile isSpace

getInt :: IO Int
getInt = fst . fromJust . readInt <$> BS.getLine

getIntList :: IO [Int]
getIntList = unfoldr readInt <$> BS.getLine
