fun main(args: Array<String>) {
    val temp=readLine()!!.split(" ")
    val a = temp[0].toInt()
    val b = temp[1].toInt()
    val bg= if(a>b)a else b
    val sm= if(a>b)b else a
    val bg_s = if(a>b)"." else "#"
    val sm_s = if(a>b)"#" else "."

    val arr = Array(100,{i: Int -> Array(100,{sm_s})})
    var count=0
    for(i in 1..97 step 4){
        for(j in 1..97 step 4){
            if(count>=bg){
                break
            }
            for(k in i-1..i+1) {
                for(l in j-1..j+1) {
                    arr[k][l]=bg_s
                }
            }
            if(count<sm-1){
                arr[i][j]= sm_s
            }
            count++
        }
    }
    println("100 100")
    for(i in 0 until 100){
        for(j in 0 until 100){
            print(arr[i][j])
        }
        if(i<99)println()
    }
}