h,w,k=gets.chomp.split(" ").map(&:to_i)
ans = 0
arr = Array.new()
h.times do
  arr.push($stdin.gets.chomp.split(''))
end
[0, 1].repeated_permutation(h) do |nuru_h|
  arr_sousa = []
  h.times do |i|
    if nuru_h[i] == 0
      arr_sousa.push(arr[i])
    end
  end
  [0, 1].repeated_permutation(w) do |nuru_w|
  arr_d = arr_sousa.dup
  arr_d = arr_d.transpose
    w.times do |j|
      if nuru_w[j] == 1
        arr_d[j] = []
      end
    end

    arr_d.flatten!
    if  arr_d.count("#") == k
      ans += 1
    end
  end
end
puts ans