#include <bits/stdc++.h>
using namespace std;
template <typename T1, typename T2>
inline void chkmin(T1 &x, T2 y) {
  if (x > y) x = y;
}
template <typename T1, typename T2>
inline void chkmax(T1 &x, T2 y) {
  if (x < y) x = y;
}
template <typename T, typename U>
inline ostream &operator<<(ostream &_out, const pair<T, U> &_p) {
  _out << _p.first << ' ' << _p.second;
  return _out;
}
template <typename T, typename U>
inline istream &operator>>(istream &_in, pair<T, U> &_p) {
  _in >> _p.first >> _p.second;
  return _in;
}
template <typename T>
inline ostream &operator<<(ostream &_out, const vector<T> &_v) {
  if (_v.empty()) {
    return _out;
  }
  _out << _v.front();
  for (auto _it = ++_v.begin(); _it != _v.end(); ++_it) {
    _out << ' ' << *_it;
  }
  return _out;
}
template <typename T>
inline istream &operator>>(istream &_in, vector<T> &_v) {
  for (auto &_i : _v) {
    _in >> _i;
  }
  return _in;
}
template <typename T>
inline ostream &operator<<(ostream &_out, const set<T> &_s) {
  if (_s.empty()) {
    return _out;
  }
  _out << *_s.begin();
  for (auto _it = ++_s.begin(); _it != _s.end(); ++_it) {
    _out << ' ' << *_it;
  }
  return _out;
}
template <typename T>
inline ostream &operator<<(ostream &_out, const multiset<T> &_s) {
  if (_s.empty()) {
    return _out;
  }
  _out << *_s.begin();
  for (auto _it = ++_s.begin(); _it != _s.end(); ++_it) {
    _out << ' ' << *_it;
  }
  return _out;
}
template <typename T>
inline ostream &operator<<(ostream &_out, const unordered_set<T> &_s) {
  if (_s.empty()) {
    return _out;
  }
  _out << *_s.begin();
  for (auto _it = ++_s.begin(); _it != _s.end(); ++_it) {
    _out << ' ' << *_it;
  }
  return _out;
}
template <typename T>
inline ostream &operator<<(ostream &_out, const unordered_multiset<T> &_s) {
  if (_s.empty()) {
    return _out;
  }
  _out << *_s.begin();
  for (auto _it = ++_s.begin(); _it != _s.end(); ++_it) {
    _out << ' ' << *_it;
  }
  return _out;
}
template <typename T, typename U>
inline ostream &operator<<(ostream &_out, const map<T, U> &_m) {
  if (_m.empty()) {
    return _out;
  }
  _out << '(' << _m.begin()->first << ": " << _m.begin()->second << ')';
  for (auto _it = ++_m.begin(); _it != _m.end(); ++_it) {
    _out << ", (" << _it->first << ": " << _it->second << ')';
  }
  return _out;
}
template <typename T, typename U>
inline ostream &operator<<(ostream &_out, const unordered_map<T, U> &_m) {
  if (_m.empty()) {
    return _out;
  }
  _out << '(' << _m.begin()->first << ": " << _m.begin()->second << ')';
  for (auto _it = ++_m.begin(); _it != _m.end(); ++_it) {
    _out << ", (" << _it->first << ": " << _it->second << ')';
  }
  return _out;
}
const string FILENAME = "input";
const int MAXN = 100001;
int n, m, q;
vector<int> g[MAXN];
bool used[MAXN];
int deep[MAXN];
int jump[MAXN][19];
int in[MAXN], out[MAXN];
int timer = 0;
void dfs(int u) {
  in[u] = timer++;
  used[u] = true;
  jump[u][0] = u;
  for (auto h : g[u]) {
    if (!used[h]) {
      deep[h] = deep[u] + 1;
      dfs(h);
    } else {
      if (deep[h] < deep[jump[u][0]]) {
        jump[u][0] = h;
      }
    }
  }
  out[u] = timer;
}
bool is_ancestor(int a, int b) { return in[a] <= in[b] && out[b] <= out[a]; }
int get(int a, int b) {
  int ans = 0;
  if (!is_ancestor(a, b)) {
    for (int k = 18; k >= 0; k--) {
      if (!is_ancestor(jump[a][k], b)) {
        a = jump[a][k];
        ans += (1 << k);
      }
    }
    a = jump[a][0];
    ans++;
  }
  swap(a, b);
  if (!is_ancestor(a, b)) {
    for (int k = 18; k >= 0; k--) {
      if (!is_ancestor(jump[a][k], b)) {
        a = jump[a][k];
        ans += (1 << k);
      }
    }
    a = jump[a][0];
    ans++;
  }
  return ans;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m >> q;
  for (int i = 0; i < m; i++) {
    int a, b;
    cin >> a >> b;
    a--, b--;
    g[a].push_back(b);
    g[b].push_back(a);
  }
  dfs(0);
  for (int k = 1; k <= 18; k++) {
    for (int i = 0; i < n; i++) {
      jump[i][k] = jump[jump[i][k - 1]][k - 1];
    }
  }
  for (int it = 0; it < q; it++) {
    int a, b;
    cin >> a >> b;
    a--, b--;
    cout << min(get(a, b), get(b, a)) << '\n';
  }
  return 0;
}
