#include<fstream>
#include<iostream>
#include<sstream>
#include<vector>
#include<stack>
#include<string>
#include<algorithm>
#include<cmath>
#include<unordered_map>
#include<map>
#include<queue>
#include<tuple>
#include<iomanip>
#include<bitset>
#include<stdio.h>
#include<set>
#include<array>
using namespace std;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
using graph = vector<vector<int>>;
const long long MOD = 1000000007;
const long long INF = 1e18;
using ll = long long;
using P = pair<int,int>;
using matrix = vector<vector<ll>>;

void chmin(int &x,int y){ x = min(x,y); }

int digit(ll x){
  int count = 1;
  while(x/10>0){
    count ++;
    x /= 10;
  }
  return count;
}

bool prime(ll x){
  if(x==1) return false;
  for(ll i=2;i*i<=x;i++){
    if(x%i==0) return false;
  }
  return true;
}

void decom(ll x,map<ll,int> &hatano){
  for(ll i=2;i*i<=x;i++){
    if(x%i==0&&prime(i)){
      while(x%i==0){
      x /= i;
      hatano[i] ++;
    }
    }
  }
  if(x!=1) hatano[x] ++;
}

ll speedpow(ll x,ll y){
  ll res = 1;
  ll test = x;
  for(int i=0;i<31;i++){
    if(y&(1<<i)) res *= test;
    res = res%MOD;
    test = (test*test)%MOD;
  }
  return res;
}

ll combination(ll x,ll y){
  ll test = 1;
  ll test1 = 1;
  for(ll i=0;i<y;i++){
    test = (test*(x-i))%MOD;
    test1 = (test1*(i+1LL))%MOD;
  }
  return (test * speedpow(test1,MOD-2))%MOD ;
}

int euclid(int x,int y){
  if(y==0) return x;
  return euclid(y,x%y);
}

//行列累乗


matrix mul(matrix &a, matrix &b) {
  int p = a.size();
    matrix res(p, vector<long long>(p, 0));
    for(int i = 0; i < p; i++)
        for(int j = 0; j < p; j++)
            for(int k = 0; k < p; k++)
                (res[i][j] += a[i][k] * b[k][j]) %= MOD;
    return res;
}


matrix pow(matrix m, long long k) {
  int p = m.size();
    matrix res(p, vector<long long>(p, 0));
    for(int i = 0; i < p; i++)
        res[i][i] = 1; // 単位行列にする

    while(k > 0) {
        if(k & 1) res = mul(res, m);
        m = mul(m, m);
        k >>= 1;
    }
    return res;
}


int main(){
    int n,m,q;cin >> n >> m >> q;
    int v[n],w[n];
    vector<P> hatano;
    int x[m];
    vector<P> konishi;

    int l[q],r[q];
    rep(i,n){
      cin >> w[i] >> v[i];
      hatano.push_back(make_pair(v[i],w[i]));
    }

    sort(hatano.rbegin(),hatano.rend());
    rep(i,m){
      cin >> x[i];
      konishi.push_back(make_pair(x[i],i));
    }
    sort(konishi.begin(),konishi.end());
    vector<int> ans;

    rep(i,q){
      cin >> l[i] >> r[i];
      l[i] --;r[i] --;
    }
    rep(i,q){
      int test=0;
      vector<bool> check(m,true);
      for(int s=l[i];s<=r[i];s++) check[s] = false;

        rep(j,n){
          rep(k,m){
            if(konishi[k].first>=hatano[j].second&&check[konishi[k].second]){
              test += hatano[j].first;
              check[konishi[k].second] = false;
             // cout << hatano[j].first << endl;
              break;
            }
          }
        }
        ans.push_back(test);
      //  cout << endl;
    }

    for(auto e:ans) cout << e << endl;

  }

#pragma GCC target("avx2")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")

#include <bits/stdc++.h>

using namespace std;

#define DEBUG
#ifdef DEBUG
inline void debug_print() { cerr << endl; }
template <typename T1, typename... T2> void debug_print(const T1 a, const T2 &... b) { cerr << a << ' '; debug_print(b...); }
#define debug(...) cerr << __LINE__ << ": [" << #__VA_ARGS__ << "] = " , debug_print(__VA_ARGS__);
#else
#define debug(...) true
#endif

inline void print() { cout << '\n'; }
template <typename T1, typename... T2> void print(const T1 a, const T2 &... b) { cout << a << ' '; print(b...); }

template <typename T1, typename T2> ostream &operator<<(ostream &os, const pair<T1, T2> &p) { os << '(' << p.first << ", " << p.second << ')'; return os; }
template <typename T> ostream &operator<<(ostream &os, const vector<T> &v) { for (auto e : v) os << e << ' '; return os; }
template <typename T> ostream &operator<<(ostream &os, const set<T> &v) { for (auto e : v) os << e << ' ';  return os; }
template <typename T> ostream &operator<<(ostream &os, const multiset<T> &v) { for (auto e : v) os << e << ' ';  return os; }
template <typename T1, typename T2> ostream &operator<<(ostream &os, const map<T1, T2> &mp) { for (auto e : mp) os << e << ' '; return os; }

template <typename T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } else return false; }
template <typename T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } else return false; }

//-------------------------- Libraries --------------------------//

//---------------------------- Solve ----------------------------//

void solve() {
    int N, M, Q;
    cin >> N >> M >> Q;

    vector<pair<int, int>> vw(N);
    for (int i = 0; i < N; i++) {
        int w, v;
        cin >> w >> v;
        vw[i] = {v, w};
    }
    sort(vw.rbegin(), vw.rend());

    vector<int> x(M);
    for (int i = 0; i < M; i++) cin >> x[i];

    while (Q--) {
        int L, R;
        cin >> L >> R;
        L--; R--;
        multiset<int> se;
        for (int i = 0; i < M; i++) {
            if (L <= i && i <= R) continue;
            se.insert(x[i]);
        }
        int ans = 0;
        for (auto [v, w] : vw) {
            auto it = se.lower_bound(w);
            if (it != se.end()) {
                ans += v;
                se.erase(se.find(*it));
            }
        }
        cout << ans << '\n';
    }
}

int main() {
    cin.tie(nullptr);
    ios_base::sync_with_stdio(false);
    cout << fixed << setprecision(20);

    int t = 1;
    //cin >> t;
    while (t--) solve();

    return 0;
}
