//AUTHOR: RAVAN_2070
//PUNE INSTITUTE OF COMPUTER TECHNOLOGY
/*                                                    
      I ♥ CLARICE STARLING...                                                               
        EXPLAINATION BELOW->
*/
#include<bits/stdc++.h>
using namespace std;
typedef unsigned long long int ull;
typedef long long int ll;
typedef long double ld;
typedef vector<ll> vi;
typedef vector<pair<ll,ll>> vii;
typedef pair<ll,ll> pii;
typedef map<ll,ll> mii;
#define MOD7 1000000007
#define MOD9 1000000009
#define pi 3.1415926535
#define Test_cases ll TC;cin>>TC;while(TC--)
#define fastio ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
#define pb push_back
#define mp make_pair
#define F first
#define S second
#define all(x) x.begin(),x.end()
#define rall(x) x.rbegin(), x.rend()
#define sp(x) fixed<<setprecision(x)
#define sz(x) (ll)(x.size())
#define fo(i,a,b) for(i=a;i<b;i++)
#define foe(i,a,b) for(i=a;i<=b;i++)
const ll INF = (ll)2e18 + 77;
void solve()
{
   int h,w,i,j,k,total=0,rq;cin>>h>>w>>k;
   char M[h][w];
   fo(i,0,h)
   fo(j,0,w)
   {
       cin>>M[i][j];
       if(M[i][j]=='#')total++;
   }
   
   vector<int>r(h,0);
   vector<int>c(w,0);
   map<int,int>R,C;
   fo(i,0,h)
   fo(j,0,w)
   if(M[i][j]=='#')r[i]++;
   
   fo(j,0,w)
   fo(i,0,h)if(M[i][j]=='#')c[j]++;
   
   int rmask,cmask;
   ll ans=0;
   for(rmask=0;rmask<(1<<h);rmask++)
   {
       for(cmask=0;cmask<(1<<w);cmask++)
       {
           int sum=0;
           vector<int>binr(h,0);
           vector<int>binc(w,0);
           i=h-1;
           int n=rmask;
           while (n > 0) 
           { 
             binr[i] = n % 2; 
             n = n / 2; 
             i--; 
           }
           
           n=cmask;
           i=w-1;
           while (n > 0) 
           { 
             binc[i] = n % 2; 
             n = n / 2; 
             i--; 
           }
           
           fo(i,0,h)
           {
               fo(j,0,w)
               {
                   if(binr[h-1-i]==0&&binc[w-1-j]==0&&M[i][j]=='#')sum++;
               }
           }
           if(sum==k)ans++;

       }
   }
   /*fo(i,0,h)R[r[i]]++;
   fo(j,0,w)C[c[j]]++;
   rq=total-k;
   
   ll ans=0;
   fo(i,0,h)if(r[i]==rq)ans++;
   fo(j,0,w)if(c[j]==rq)ans++;
   
   fo(i,0,h)
   {
      fo(j,0,w)
      {
          ll sum=0;
          if(M[i][j]=='#')sum=-1;
          sum=sum+r[i]+c[j];
          if(sum==rq)ans++;
      } 
   }
   
   fo(i,0,h)
   {
       for(j=i+1;j<h;j++)
       {
           ll sum=r[i]+r[j];
           if(sum==rq)ans++;
      } 
       }
    
    
    for(i=0;i<w;i++)
   {
       for(j=i+1;j<w;j++)
       {
           ll sum=c[i]+c[j];
           if(sum==rq)ans++;
       } 
    }*/
    cout<<ans<<"\n";
   
}
int main()
{
   fastio
   //Test_cases
   solve();
  return 0;
}
//map<ll,ll,greater<int>> to sort in descending order ,in iterator declaration no greater<int>
//if you want to apply lowerbound on set use s.lower_bound(key),not the one used for vector
// Syntax to create a min heap for priority queue priority_queue <int, vector<int>, greater<int>>; 
//for modinverse use modularexponention(x,M-2,M);
//for "each" subtraction from ans(ans-k) if(ans<0) do ans+=MOD,ans%=MOD
//vector<vector<int>>dp(201,vector<int>(n+1)); A way to initialize vector of vector
//If wrong on pretest 2 means logically wrong


/* TIPS FOR DEBUGGING
 * Check if values are not overflowing (use long long where required)
 * Check if ranges are inclusive or not.
 * Check properly if greedy will work or not before using it.
 * Check EDGE CASES!! Seriously, even in 2B, saving 8 points by being
 * 2 minutes faster will bite you in the ass if you don't make sure
 * it works on edge cases.
 * Keep adding to this list.
*/


Measured memory_bytes: 3652