/*Ankon Ghosh
  KUET,ECE 2K16*/
#include<bits/stdc++.h>
/*#include <ext/pb_ds/assoc_container.hpp> // Common file
#include <ext/pb_ds/tree_policy.hpp> // Including tree_order_statistics_node_update
///#include <ext/pb_ds/detail/standard_policies.hpp>*/
///using namespace __gnu_pbds;
using namespace std;
using ll=long long;
#define inf 1e16
#define MAX 100005
#define mod 998244353
#define sf(a) scanf("%lld",&a)
#define sff(a,b) scanf("%lld %lld",&a,&b)
#define sfff(a,b,c) scanf("%lld %lld %lld",&a,&b,&c)
#define Case(i) printf("Case %lld: ",i)
#define setpre(number) cout<<fixed<<setprecision(10)<<number<<endl
#define pf(a) printf("%lld ",a)
#define pff(a,b) printf("%lld %lld\n",a,b)
#define FOR(i,n) for(ll i=0;i<n;i++)
#define FOR1(i,n) for(ll i=1;i<=n;i++)
#define LOOP(x,y) for(ll i=x;i<=y;i++)
#define RFOR(i,n) for(ll i=n-1;i>=0;i--)
#define RFOR1(i,n) for(ll i=n;i>0;i--)
#define RLOOP(x,y) for(ll i=y;i>=x;i--)
#define m_p make_pair
#define ff first
#define ss second
#define p_b push_back
#define fast ios_base::sync_with_stdio(false); cin.tie(NULL)
#define output freopen("output.txt","w",stdout)
map<ll,ll>mp1,mp;
vector<pair<ll,pair<ll,ll> > >vpp1;
vector<pair<ll,ll> >vpp,vp1;
vector<ll>v,v1,v2,fin;
map<pair<ll,ll>,bool>mbb;
map<ll,bool>mb,mb1;
ll a,b,c,n,d,e,f,ta,sum=0,cnt=0,m,l,req,sz,maxi,k;
void makeCombiUtil(vector<vector<ll> >& ans,
                   vector<ll>& tmp, ll n, ll left, ll k)
{
    // Pushing this vector to a vector of vector
    if (k == 0)
    {
        ans.push_back(tmp);
        return;
    }

    // i iterates from left to n. First time
    // left will be 1
    for (ll  i = left; i <= n; ++i)
    {
        tmp.push_back(i);
        makeCombiUtil(ans, tmp, n, i + 1, k - 1);

        // Popping out last inserted element
        // from the vector
        tmp.pop_back();
    }
}

// Prints all combinations of size k of numbers
// from 1 to n.
vector<vector<ll> > makeCombi(ll n, ll k)
{
    vector<vector<ll> > ans;
    vector<ll> tmp;
    makeCombiUtil(ans, tmp, n, 1, k);
    return ans;
}
char grid[10][10];
int main()
{
    cin>>n>>m>>k;
    FOR1(i,n)
    {
        FOR1(j,m)
        cin>>grid[i][j];
    }
    vector<vector<ll> >row,col;
    vector<ll>fun;
    fun.p_b(0LL);
    col.p_b(fun);
    row.p_b(fun);
    for(ll i=1; i<=n; i++)
    {
        vector<vector<ll> > ans = makeCombi(n, i);
        vector<ll>ok;
        for (ll i = 0; i < ans.size(); i++)
        {
            ok.clear();
            for (int j = 0; j < ans[i].size(); j++)
            {
                ok.p_b(ans[i][j]);
            }
            row.p_b(ok);
            ///cout << endl;
        }
    }
    for(ll i=1; i<=m; i++)
    {
        vector<vector<ll> > ans = makeCombi(m, i);
        vector<ll>ok;
        for (ll i = 0; i < ans.size(); i++)
        {
            ok.clear();
            for (int j = 0; j < ans[i].size(); j++)
            {
                ok.p_b(ans[i][j]);
            }
            col.p_b(ok);
            ///cout << endl;
        }
    }
    ll cnt=0,ans=0;
    for(ll i=0;i<row.size();i++)
    {
        for(ll j=0;j<col.size();j++)
        {
            vector<ll>dum=row[i];
            vector<ll>dumm=col[j];
            mb.clear();
            mb1.clear();
            cnt=0;
            for(ll u=0;u<dum.size();u++)
            {
                mb[dum[u]]=1;
                ///cout<<dum[u]<<" ";
            }
            ///cout<<"||";
            for(ll u=0;u<dumm.size();u++)
            {
                mb1[dumm[u]]=1;
               ///cout<<dumm[u]<<" ";
            }
            for(ll x=1;x<=n;x++)
            {
                for(ll y=1;y<=m;y++)
                {
                    if(mb[x]==0 and mb1[y]==0)
                    {
                        if(grid[x][y]=='#') cnt++;
                    }
                }
            }
            if(cnt==k)
            {
              ans++;
            }
            ///cout<<endl;
        }
    }
    cout<<ans<<endl;
    return 0;
}


Measured memory_bytes: 3644