<?php
while (true) {
    list($height, $width) = getSpacesByExplodeTrimInput();
    
    if ($height == 0 && $width == 0) {
        break;
    }

    for ($i = 1; $i <= $height; $i++) {
        if ($i % 2 == 0) {
                $lines[] = setEvenNumLine($width);
        } else {
                $lines[] = setOddNumLine($width);
        }
    }
}

echo implode($lines), PHP_EOL;

function getSpacesByExplodeTrimInput()
{
    return explode(' ', trim(fgets(STDIN)));
}

function setEvenNumLine($width)
{
    $line = "";
    for ($i = 1; $i <= $width; $i++) {
        $line .= $i % 2 == 0 ? "#" : ".";
    }
    return $line.PHP_EOL;
}

function setOddNumLine($width)
{
    $line = "";
    for ($i = 1; $i <= $width; $i++) {
        $line .= $i % 2 == 0 ? "." : "#";
    }
    return $line.PHP_EOL;
}