h, w, k = gets.split.map(&:to_i)
rows = Array.new(h){gets.chomp.bytes.map{|c| (c == '#'.ord) ? 1 : 0}}
cnt = 0
[0, 1].repeated_permutation(h) do |x|
  m = []
  x.each_with_index do |y, i|
    if y == 0
      m << rows[i].dup
    else
      m << [0] * w
    end
  end
  [0, 1].repeated_permutation(w) do |u|
    mc = []
    u.each_with_index do |v, l|
      if v == 0
        mc << m.transpose[l]        
      end
    end
    cnt += 1 if mc.flatten.sum == k
  end
end
puts cnt