var line, even, odd, i, res, hw;

// even : #.#.
// odd  : .#.#

even = {1: '#', 2: '#.'};
odd = {1: '.', 2: '.#'};

line = require('fs').readFileSync('/dev/stdin', 'ascii').split("\n");
line.length = line.lastIndexOf('0 0');

res = [];
for (i in line) {
	hw = line[i].split(' ').map(Number);
	res.push(get_area(hw[0], hw[1]));
	res.push("");
}
console.log(res.join('\n'));

function get_area(h, w) {
	var top, bottom;
	if (h >= 3) {
		top = Math.floor(h / 2);
		if (top % 2 === 1) top++;
		bottom = h - top;
		return get_area(top, w) + '\n' + get_area(bottom, w);
	} else if (h == 1) {
		return get_even(w);
	} else if (h == 2) {
		return get_even(w) + '\n' + get_odd(w);
	}
}

function get_even(n) {
	var i, smaller;
	if (n in even) return even[n];
	if (n % 2 === 0) {
		i = n / 2;
		smaller = get_even(i);
		return smaller + ((i % 2 === 0) ? smaller : get_odd(i));
	}
	return get_even(n - 1) + '#';
}

function get_odd(n) {
	var i, smaller;
	if (n in odd) return odd[n];
	if (n % 2 === 0) {
		i = n / 2;
		smaller = get_odd(i);
		return smaller + ((i % 2 === 0) ? smaller : get_even(i));
	}
	return get_odd(n - 1) + '.';
}