h,w,k = gets.split(" ").map(&:to_i)

#読み込み
board = []
h.times do
    row = gets.chomp.split("").slice(0,w).map{|c| c=="." ? 0 : 1}
    board.push(row)
end


#行・列の組み合わせ
def combs(count)
    cells = Array.new(count){|i| i}
    cells_com = []
    for c in  (0..count-1) do
        com = cells.combination(c).to_a
        cells_com = cells_com.concat(com)
    end
    return cells_com
end

row_set = combs(h)
col_set = combs(w)

case_count  = 0

row_set.each {|rows|
    col_set.each{|cols|
        black_count = 0
        for r in (0..h-1) do
            if !rows.include?(r)
                for c in (0..w-1) do
                    black_count += board[r][c] unless cols.include?(c)
                end
            end
        end
        case_count += 1 if black_count == k
    }
}

puts case_count
