#include <bits/stdc++.h>
#include <algorithm>
#define rep(i,n) for (int i = 0; i < (n); ++i)
using namespace std;

int main() {
    int h,w,k;
    cin >> h >> w>> k;
    vector<string> s(h);
    rep(i,h) cin >> s.at(i);
    int ans = 0;
    rep(is,1<<h)rep(js,1<<w) {
     int cnt = 0;
    rep(i,h)rep(j,w){
     if(is>>i&1)continue;
    if(js>>j&1)continue;
    if(s[i][j] == '#') cnt++;
    }
    if(cnt ==k) ans++;
    }
    cout << ans << endl;
}