h, w, k = gets.chomp.split.map(&:to_i)
c = []
h.times do
  c << gets.chomp.chars
end

res = 0

(1 << h).times do |i|
  (1 << w).times do |j|
    cnt = 0
    h.times do |h_i|
      w.times do |w_i|
        if c[h_i][w_i] == "#" && i[h_i] == 0 && j[w_i] == 0
          cnt += 1
        end
      end
    end
    if cnt == k
      res += 1
    end
  end
end

puts res
