import numpy as np

import sys



n, m, q = list(map(int, input().split()))

ab = np.array(sys.stdin.read().split(), np.int)

a = ab[:m*2].reshape(m, 2)

b = ab[m*2:].reshape(q, 2)



x=np.zeros((501, 501), dtype=np.int)



np.add.at(x, (a[:, 0], a[:, 1]), 1)



np.cumsum(x, axis=0, out=x)

np.cumsum(x, axis=1, out=x)



for i in range(q):

    v1=b[i][0]

    v2=b[i][1]

    

    a1=x[v2, v2]

    a2=x[v2, v1-1]

    a3=x[v1-1, v2]

    a4=x[v1-1, v1-1]

    print((a1-a2-a3+a4))

import numpy as np

import sys



n, m, q = list(map(int, input().split()))

ab = np.array(sys.stdin.read().split(), np.int)

a = ab[:m*2].reshape(m, 2)

b = ab[m*2:].reshape(q, 2)



x=np.zeros((501, 501), dtype=np.int)



np.add.at(x, (a[:, 0], a[:, 1]), 1)



np.cumsum(x, axis=0, out=x)

np.cumsum(x, axis=1, out=x)



ans = x[b[:, 1], b[:, 1]] - x[b[:, 1], b[:, 0]-1] - x[b[:, 0]-1, b[:, 1]] + x[b[:, 0]-1, b[:, 0]-1]

for i in range(q):

    print((ans[i]))

import numpy as np
import sys

n, m, q = list(map(int, input().split()))
ab = np.array(sys.stdin.read().split(), np.int)
a = ab[: m * 2].reshape(m, 2)
b = ab[m * 2 :].reshape(q, 2)
x = np.zeros((501, 501), dtype=np.int)
np.add.at(x, (a[:, 0], a[:, 1]), 1)
np.cumsum(x, axis=0, out=x)
np.cumsum(x, axis=1, out=x)
for i in range(q):
    v1 = b[i][0]
    v2 = b[i][1]
    a1 = x[v2, v2]
    a2 = x[v2, v1 - 1]
    a3 = x[v1 - 1, v2]
    a4 = x[v1 - 1, v1 - 1]
    print((a1 - a2 - a3 + a4))

import numpy as np
import sys

n, m, q = list(map(int, input().split()))
ab = np.array(sys.stdin.read().split(), np.int)
a = ab[: m * 2].reshape(m, 2)
b = ab[m * 2 :].reshape(q, 2)
x = np.zeros((501, 501), dtype=np.int)
np.add.at(x, (a[:, 0], a[:, 1]), 1)
np.cumsum(x, axis=0, out=x)
np.cumsum(x, axis=1, out=x)
ans = (
    x[b[:, 1], b[:, 1]]
    - x[b[:, 1], b[:, 0] - 1]
    - x[b[:, 0] - 1, b[:, 1]]
    + x[b[:, 0] - 1, b[:, 0] - 1]
)
for i in range(q):
    print((ans[i]))

+ans = ( +    x[b[:, 1], b[:, 1]] +    - x[b[:, 1], b[:, 0] - 1] +    - x[b[:, 0] - 1, b[:, 1]] +    + x[b[:, 0] - 1, b[:, 0] - 1] +) -    v1 = b[i][0] -    v2 = b[i][1] -    a1 = x[v2, v2] -    a2 = x[v2, v1 - 1] -    a3 = x[v1 - 1, v2] -    a4 = x[v1 - 1, v1 - 1] -    print((a1 - a2 - a3 + a4)) +    print((ans[i]))