#include <bits/stdc++.h>
using namespace std;
int n, m, Q, he[100011], ne[500011 << 1], e[500011 << 1], cnt, dep[100011],
    U[100011], fa[100011][20], up[100011][20], vis[100011];
inline int read() {
  char ch = getchar();
  int x = 0;
  for (; ch > '9' || ch < '0'; ch = getchar())
    ;
  for (; ch >= '0' && ch <= '9'; ch = getchar()) x = x * 10 + ch - '0';
  return x;
}
void add(int u, int v) {
  ne[++cnt] = he[u];
  he[u] = cnt;
  e[cnt] = v;
}
void dfs(int x, int f) {
  fa[x][0] = f;
  dep[x] = dep[f] + 1;
  U[x] = f;
  vis[x] = 1;
  for (int i = 1; fa[x][i - 1]; i++) fa[x][i] = fa[fa[x][i - 1]][i - 1];
  for (int i = he[x]; i; i = ne[i]) {
    if (e[i] == f) continue;
    if (dep[e[i]] && (dep[e[i]] < dep[U[x]])) U[x] = e[i];
    if (!vis[e[i]]) dfs(e[i], x);
  }
}
void dfs(int x) {
  up[x][0] = U[x];
  vis[x] = 1;
  for (int i = 1; up[x][i - 1]; i++) up[x][i] = up[up[x][i - 1]][i - 1];
  for (int i = he[x]; i; i = ne[i])
    if (!vis[e[i]]) dfs(e[i]);
}
int LCA(int u, int v) {
  if (dep[u] < dep[v]) swap(u, v);
  for (int i = 18; ~i; i--)
    if (dep[fa[u][i]] >= dep[v]) u = fa[u][i];
  if (u == v) return u;
  for (int i = 18; ~i; i--)
    if (fa[u][i] != fa[v][i]) {
      u = fa[u][i];
      v = fa[v][i];
    }
  if (u == v)
    return u;
  else
    return fa[u][0];
}
int main() {
  n = read();
  m = read();
  Q = read();
  for (int i = 1; i <= m; i++) {
    int u = read(), v = read();
    add(u, v);
    add(v, u);
  }
  dfs(1, 0);
  memset(vis, 0, sizeof(vis));
  dfs(1);
  while (Q--) {
    int u = read(), v = read(), L = LCA(u, v);
    int res = 0;
    if (u != L) {
      for (int i = 18; ~i; i--)
        if (dep[up[u][i]] > dep[L]) u = up[u][i], res += (1 << i);
      res++;
    }
    if (v != L) {
      for (int i = 18; ~i; i--)
        if (dep[up[v][i]] > dep[L]) v = up[v][i], res += (1 << i);
      res++;
    }
    printf("%d\n", res);
  }
  return 0;
}
