open System 
open System.Text

type Explicit =          
    static member inline ($) (_:int32, _:Explicit) = int
    static member inline ($) (_:int64, _:Explicit) = int64

let inline convert (value:'a): 'b = 
    (Unchecked.defaultof<'b> $ Unchecked.defaultof<Explicit>) value

let inline fromInt (x: int): 'a = convert x

module NumericLiteralG =
    let inline FromZero(): ^a = LanguagePrimitives.GenericZero
    let inline FromOne(): ^a = LanguagePrimitives.GenericOne
    let inline FromInt32 n = fromInt n

let R() = Console.ReadLine()

let f (n: int) (m: int) =
    if n < m then 
        Seq.initInfinite (fun _ -> n)
        |> Seq.take m 
    else 
        Seq.initInfinite (fun _ -> m)
        |> Seq.take n 
    |> Seq.fold (fun (acc: StringBuilder) x -> acc.Append x) (StringBuilder())
    |> fun x -> x.ToString()
        
let N, M = let t = R().Split() |> Array.map (string >> int) in t.[0], t.[1]

f N M 
|> printfn "%s"