loop do
  h, w = gets.split.map(&:to_i)
  break if h == 0 && w == 0
  (1..h).each do |y|
    line = '#.' * w
    line =
    if y.odd?
      line[0..w - 1]
    else
      line[1..w]
    end
    puts line
  end
  puts
end