#include <bits/stdc++.h>
using namespace std;
const int N = 13;
int n, m, k, g[N][N], p[N], L[N], R[N];
long long fac[N];
bool dp[1 << 6][6];
unordered_map<long long, int> mp;
inline void dfs1(int x) {
  if ((x << 1) == n) {
    memset(dp, false, sizeof(dp));
    for (int i = 0; i < x; ++i)
      if (g[L[i]][R[i]]) dp[1 << i][i] = 1;
    for (int i = 0; i < (1 << x); ++i)
      for (int j = 0; j < x; ++j) {
        if (!dp[i][j]) continue;
        for (int k = 0; k < x; ++k)
          if (!(i & (1 << k)))
            dp[i | (1 << k)][k] |= (g[L[j]][L[k]] && g[R[j]][R[k]]) ||
                                   (g[L[j]][R[k]] && g[R[j]][L[k]]);
      }
    int tot = (1 << x) - 1;
    long long now = 0;
    bool ret = 0;
    for (int i = 1; i <= n; ++i) now = now * 6 + p[i];
    for (int i = 0; i < x; ++i)
      if (dp[tot][i]) {
        ret = true;
        break;
      }
    mp[now] = ret;
    return;
  }
  for (int i = 1; i <= n; ++i) {
    if (p[i] == -1) {
      for (int j = i + 1; j <= n; ++j)
        if (p[j] == -1) {
          p[i] = p[j] = x;
          L[x] = i;
          R[x] = j;
          dfs1(x + 1);
          p[i] = p[j] = -1;
        }
      break;
    }
  }
}
inline bool check(vector<int> p) {
  vector<int> ct(n >> 1), lst(n >> 1);
  long long now = 0;
  int tot = 0;
  for (int i = 0; i < (n >> 1); ++i) lst[i] = -1;
  for (int i = 1; i <= n; ++i) {
    if (lst[p[i]] == -1) lst[p[i]] = tot++;
    p[i] = lst[p[i]];
    now = now * 6 + p[i], ct[p[i]]++;
  }
  if (mp.count(now)) return mp[now];
  for (int i = 1; i <= n; ++i) {
    if (ct[p[i]] > 2) {
      for (int j = i + 1; j <= n; ++j) {
        if (p[i] == p[j]) {
          int rec = p[i];
          p[i] = p[j] = tot;
          bool ret = check(p);
          p[i] = p[j] = rec;
          if (ret) return mp[now] = true;
        }
      }
      break;
    }
  }
  return mp[now] = false;
}
inline void dfs2(int x) {
  int pos = -1;
  for (int i = 1; i <= n; ++i)
    if (p[i] == -1) {
      pos = i;
      break;
    }
  if (pos == -1) {
    vector<int> ve(n + 1);
    for (int i = 1; i <= n; ++i) ve[i] = p[i];
    check(ve);
    return;
  }
  for (int k = 0; k <= x; ++k) {
    for (int y = pos + 1; y <= n; ++y) {
      if (p[y] == -1) {
        p[pos] = p[y] = k;
        dfs2(max(k + 1, x));
        p[pos] = p[y] = -1;
      }
    }
  }
}
int main() {
  scanf("%d%d%d", &n, &m, &k);
  for (int i = 1, u, v; i <= m; ++i) {
    scanf("%d%d", &u, &v);
    g[u][v] = g[v][u] = 1;
  }
  for (int i = 1; i <= n; ++i) p[i] = -1;
  fac[0] = 1;
  for (int i = 1; i <= k; ++i) fac[i] = fac[i - 1] * i;
  dfs1(0);
  dfs2(0);
  long long ans = 0;
  for (auto p : mp) {
    if (!p.second) continue;
    long long mx = 0;
    long long now = p.first;
    for (int i = 1; i <= n; ++i) {
      mx = max(mx, now % 6);
      now /= 6;
    }
    mx++;
    if (mx <= k) ans = ans + fac[k] / fac[k - mx];
  }
  printf("%lld\n", ans);
  return 0;
}
