let [|a;b|] = stdin.ReadLine().Split() |> Array.map int

let f x = [1..x] |> List.map (fun y -> 10.0 ** (float (y - 1)) |> int) |> List.sum

if (a >= b) then (b * (f a)) else (a * (f b))
|>stdout.WriteLine