fun main(args: Array<String>) {
    var (a,b) = readLine()!!.split(" ").map { it.toInt() }
    println(if(a < b) p(a,b) else p(b,a))
}

fun p(a: Int, b: Int): String {
    return if (b == 1) a.toString()
    else a.toString() + p(a, b-1)
}
