#include <bits/stdc++.h>
// #include <atcoder/all>
// #include "icld.cpp"
using namespace std;
using ll = long long int;
using vi = vector<int>;
using si = set<int>;
using vll = vector<ll>;
using vvi = vector<vector<int>>;
using ss = string;
using db = double;
template<typename T> using minpq = priority_queue <T,vector<T>,greater<T>>;
const int dx[4] = {1,0,-1,0};
const int dy[4] = {0,1,0,-1};
#define V vector
#define P pair<int,int>
#define rep(i,s,n) for(int i=(s);i<(int)(n);i++)
#define rev(i,s,n) for(int i=(s);i>=(int)(n);i--)
#define reciv(v,n) vi (v)((n)); rep(i,0,(n))cin>>v[i]
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(),v.rend()
#define ci(x) cin >> x
#define cii(x) ll x;cin >> x
#define cci(x,y) ll x,y;cin >> x >> y
#define co(x) cout << x << endl
#define pb push_back
#define eb emplace_back
#define rz resize
#define sz(x) int(x.size())
#define yn cout<<"Yes"<<endl;else cout<<"No"<<endl
#define YN cout<<"YES"<<endl;else cout<<"NO"<<endl
template<class T>void chmax(T &x,T y){x=max(x,y);}
template<class T>void chmin(T &x,T y){x=min(x,y);}

int main(){
  cci(n,m);
  cii(qe);

  V<P> nmt(n);
  rep(i,0,n){
    cci(w,v);
    nmt[i]=P(w,v);
  }

  reciv(hk,m);

  vi ans(qe);
  rep(qq,0,qe){
    cci(l,r);
    l--;r--;

    minpq<int>q;
    rep(i,0,m)if(i<l or r<i)q.push(hk[i]);

    int res=0;
    vi bl(n,0);
    while(sz(q)){
      int tp=q.top();q.pop();
      int to=-1,ma=-1;

      rep(i,0,n){
        if(bl[i]==1)continue;
        int grm=nmt[i].first;
        int val=nmt[i].second;

        if(grm<=tp){
          if(ma<val){
            ma=val;
            to=i;
          }
        }
      }

      if(to!=-1){
        bl[to]=1;
        res+=ma;
      }
    }

    ans[qq]=res;
  }

  for(int x:ans)co(x);
}
#include<bits/stdc++.h>
using namespace std;
typedef int64_t ll;

typedef long double ld;
const ll MOD=1000000007;
const ll MODA=998244353;
ll vx[4]={0,1,0,-1};
ll vy[4]={1,0,-1,0};
#define rep(i,n) for(ll i=0;i<(ll)(n);i++)
long long gcd(long long a,long long b){
    ll gcdmax=max(a,b);
    ll gcdmin=min(a,b);
    while(true){
        if(gcdmax%gcdmin==0)break;
        else gcdmax%=gcdmin;
        swap(gcdmin,gcdmax);
    }
    return gcdmin;
}
ll pow(ll N,ll P,ll M){
    if(P==0)return 1;
    else if(P%2==0){
        ll t=pow(N,P/2,M);
        return t*t%M;
    }
    else return N*pow(N,P-1,M)%M;
}
vector<ll> find_divisor(ll N){
  ll k=1;
  while(k*k<=N){
    k++;
  }
  vector<ll> A(1);
  rep(i,k){
    if(i==1)A.at(0)=1;
    else if(i>=2){
      if(N%i==0)A.push_back(i);
    }
  }
  ll t=0;
  t=A.size();
  rep(i,t){
    if(A.at(t-i-1)*A.at(t-i-1)!=N)A.push_back(N/A.at(t-1-i));
  }
  return A;
}
vector<ll> fac;
vector<ll> finv;
vector<ll> inv;
void COMinit(ll N,ll P){
    rep(i,N+1){
        if(i==0){
            fac.push_back(1);
            finv.push_back(1);
            inv.push_back(1);
        }
        else if(i==1){
            fac.push_back(1);
            finv.push_back(1);
            inv.push_back(1);
        }
        else{
            fac.push_back(fac.at(i-1)*i%P);
            inv.push_back(P-inv.at(P%i)*(P/i)%P);
            finv.push_back(finv.at(i-1)*inv.at(i)%P);
        }
    }
}

ll COM(ll n,ll k,ll P){
    if(n<k)return 0;
    if(n<0||k<0)return 0;
    return fac.at(n)*(finv.at(k)*finv.at(n-k)%P)%P;
}


struct UnionFind {
    vector<ll> par; // par[i]:iの親の番号　(例) par[3] = 2 : 3の親が2

    UnionFind(ll N) : par(N) { //最初は全てが根であるとして初期化
        for(ll i = 0; i < N; i++) par[i] = i;
    }

    ll root(ll x) { // データxが属する木の根を再帰で得る：root(x) = {xの木の根}
        if (par[x] == x) return x;
        return par[x] = root(par[x]);
    }

    void unite(ll x, ll y) { // xとyの木を併合
        ll rx = root(x); //xの根をrx
        ll ry = root(y); //yの根をry
        if (rx == ry) return; //xとyの根が同じ(=同じ木にある)時はそのまま
        par[rx] = ry; //xとyの根が同じでない(=同じ木にない)時：xの根rxをyの根ryにつける
    }

    bool same(ll x, ll y) { // 2つのデータx, yが属する木が同じならtrueを返す
        ll rx = root(x);
        ll ry = root(y);
        return rx == ry;
    }
};



int main(){
    ll N,M,Q;
    cin>>N>>M>>Q;
    vector<pair<ll,ll>> bag(N);
    vector<ll> box(M);
    rep(i,N){
        cin>>bag.at(i).first>>bag.at(i).second;
    }
    rep(i,M){
        cin>>box.at(i);
    }
    sort(bag.begin(),bag.end());
    rep(i,Q){
        ll ans=0;
        ll L,R;
        ll P=0;
        cin>>L>>R;
        L--;
        R--;
        vector<ll> ava(M-R+L-1);
        vector<ll> used(N);
        rep(i,L){
            ava.at(i)=box.at(i);
        }
        for(ll i=R+1;i<M;i++){
            ava.at(L+i-R-1)=box.at(i);
        }
        sort(ava.begin(),ava.end());
        rep(i,M-R+L-1){
            ll j=0;
            ll t=-1;
            while(j<N&&bag.at(j).first<=ava.at(i)){
                if(P<bag.at(j).second&&used.at(j)==0){
                    t=j;
                    P=bag.at(j).second;
                }
                j++;
            }
            ans+=P;
            if(t>=0)used.at(t)++;
            P=0;
        }
        cout<<ans<<endl;
    }
}