import java.util.*

fun main(args: Array<String>) {
  val sc = Scanner(System.`in`)
  val h = sc.nextInt()
  val w = sc.nextInt()
  val k = sc.nextInt()
  val c = Array(h) { sc.next().toCharArray() }

  var count = 0
  for (hBit in 0 .. (1 shl h) - 1) {
    for (wBit in 0 .. (1 shl w) - 1) {
      var black = 0

      for (i in 0 until h) {
        for (j in 0 until w) {
          if ((hBit shr i) and 1 == 0 && (wBit shr j) and 1 == 0) {
            if (c[i][j] == '#') {
              black++
            }
          }
        }
      }

      if (black == k) count++

    }
  }

  println(count)

}
