local h, w, k = io.read("*n", "*n", "*n", "*l")
local t = {}
for i = 1, h do
  t[i] = {}
  local s = io.read()
  for j = 1, w do
    t[i][j] = s:sub(j, j) == "#"
  end
end
local tot = 1 << (h + w)
local hflag, wflag = {}, {}
local ans = 0
for i = 0, tot - 1 do
  local ti = i
  for j = 1, h do
    hflag[j] = ti % 2 == 0
    ti = ti // 2
  end
  for j = 1, w do
    wflag[j] = ti % 2 == 0
    ti = ti // 2
  end
  local c = 0
  for j = 1, h do
    for k = 1, w do
      if t[j][k] and hflag[j] and wflag[k] then
        c = c + 1
      end
    end
  end
  if c == k then ans = ans + 1 end
end
print(ans)
