fun main(args: Array<String>) {
    val (A, B) = listOfInt()
    val X = Array(100) { CharArray(100) }
    repeat(50) { h->
        repeat(100) { w ->
            X[h][w] = '#'
            X[h + 50][w] = '.'
        }
    }
    var x = 1; var y = 1
    repeat(A - 1) {
        X[y][x] = '.'
        x += 2
        if (x > 100) { x = 1; y += 3 }
    }
    x = 1; y = 51
    repeat(B - 1) {
        X[y][x] = '#'
        x += 2
        if (x > 100) { x = 1; y += 3 }
    }
    println("100 100")
    X.forEach { println(it.joinToString("")) }
}

fun next() = readLine()!!
fun nextInt() = next().toInt()
fun listOfString() = next().split(" ")
fun listOfInt(d: Int = 0) = listOfString().map { it.toInt() + d }
fun listOfLong(d: Long = 0) = listOfString().map { it.toLong() + d }

