#include<bits/stdc++.h>
using namespace std;
using ull=unsigned long long;
#define mod 1000000007
#define mod2 998244353 
#define PI 3.14159265
#define ll long long
#define ld long double
#define pi pair<ll,ll>
#define pb push_back
#define vi vector<ll>
#define sz size()
#define setbits(x)  __builtin_popcount(x)
#define fi first
#define se second
#define lz length()
#define all(x) (x).begin(),(x).end()
#define scf(x) scanf("%lld",&x)
#define rep(i,n) for(ll i=0;i<n;i++)
const int INF = (int)1e9;
const ll IINF=1LL<<62;
const int maxn=10000005;

//int divr[maxn];
/**/
/*void divisor()
{for(int i=2;i<sqrt(maxn);i++)
     {
          if(!divr[i])
          {
               for(int j=i*i;j<maxn;j+=i)if(!divr[j])divr[j]=i;     
          }
     }
     for(int i=1;i<maxn;i++)if(!divr[i])divr[i]=i;
}*/
 
/*const int N=1000005;
ll n;
struct line {
    long long m, c;
    long long eval(long long x) { return m * x + c; }
    long double intersectX(line l) { return (long double) (c - l.c) / (l.m - m); }
};
vector<pair<pi,ll>> rect;
deque<line> dq;
*/
/*int find(int a){
     if(a==par[a])return a;
     return par[a]=find(par[a]);
}
void unite(int a,int b){
     a=find(a),b=find(b);
     if(a==b)return ;
     par[b]=a;
}
ll modexpo(ll a,ll b)
{
     int ans=1LL;
     while(b>0)
     {
          if(b&1)ans=(ans*a)%mod;
          a=(a*a)%mod;
          b>>=1;
     }
     return ans;
}
*/















bool compare(pair<int,int> p1,pair<int,int> p2){
     if(p1.fi<p2.fi)return true;
     else if(p1.fi==p2.fi&&p1.se<p2.fi)return true;
     return false;

}

int main(){
     int h,w;
     cin>>h>>w;
     int k;
     cin>>k;
     char name[h][w];
     int ct1=0;
     for(int i=0;i<h;i++){
          string t;cin>>t;
          for(int j=0;j<t.length();j++){name[i][j]=t[j];
          if(name[i][j]=='#')ct1++;}
     }
     int left=ct1-k;
     int res=0;
     for(int i=0;i<(1<<h);i++){
          for(int j=0;j<(1<<w);j++){
               int r1[h]={0};
               for(int k=0;k<h;k++){
                    if((i>>k)&1!=0)r1[k]=1;
               }
               int c[w]={0};
               for(int k=0;k<w;k++){
                    if(((j>>k)&1)!=0)c[k]=1;
               }
               int rc=0,cc=0;
               for(int k=0;k<h;k++){
                    if(r1[k]==1){
                         for(int l=0;l<w;l++){
                              if(name[k][l]=='#')rc++;
                         }
                    }
               }
               for(int k=0;k<w;k++){
                    if(c[k]==1){
                         for(int l=0;l<h;l++){
                              if(name[l][k]=='#')cc++;
                         }
                    }
               }
               //cout<<cc<<" "<<rc<<" ";
               int total=cc+rc;
               for(int k=0;k<h;k++){
                    for(int l=0;l<w;l++){
                         if(r1[k]==1&&c[l]==1){
                              if(name[k][l]=='#')total--;
                         }
                    }
               } 
              // cout<<total<<"\n";
               if(total==left)res++;  
               
          }
     }
     cout<<res;
}



















































Measured memory_bytes: 3632