while line = gets
  h, w = line.chomp.split.map(&:to_i)
  break if h == 0 && w == 0

  h.times do |i|
    if i.even?
      w.times do |j|
        print "#" if j.even?
        print "." if j.odd?
      end
    else
      w.times do |j|
        print "." if j.even?
        print "#" if j.odd?
      end
    end
    puts
  end
  puts
end

