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

book=[[0]*(n+1) for _ in range(n+1)]

for _ in range(m):

    r,l=list(map(int,input().split()))

    book[r][l] +=1



for i in range(n+1):

    for j in range(n+1):

        book[i][j] +=book[i][j-1]



for i in range(n+1):

    for j in range(n+1):

        book[i][j] +=book[i-1][j]



for x,y in [list(map(int,input().split())) for i in range(q)]:

    print((book[y][y]-book[y][x-1]-book[x-1][y]+book[x-1][x-1]))
n,m,q=list(map(int,input().split()))

LR=[tuple(map(int,input().split())) for _ in range(m)]

PQ=[tuple(map(int,input().split())) for _ in range(q)]



MAP=[[0]*(n+1) for _ in range(n+1)]

for l,r in LR:

    MAP[l][r] +=1



for i in range(n+1):

    for j in range(n+1):

        MAP[i][j] +=MAP[i][j-1]



for i in range(n+1):

    for j in range(n+1):

        MAP[i][j] +=MAP[i-1][j]



for p,q in PQ:

    print((MAP[q][q]-(MAP[q][p-1]+MAP[p-1][q])+MAP[p-1][p-1]))
n, m, q = list(map(int, input().split()))
book = [[0] * (n + 1) for _ in range(n + 1)]
for _ in range(m):
    r, l = list(map(int, input().split()))
    book[r][l] += 1
for i in range(n + 1):
    for j in range(n + 1):
        book[i][j] += book[i][j - 1]
for i in range(n + 1):
    for j in range(n + 1):
        book[i][j] += book[i - 1][j]
for x, y in [list(map(int, input().split())) for i in range(q)]:
    print((book[y][y] - book[y][x - 1] - book[x - 1][y] + book[x - 1][x - 1]))

n, m, q = list(map(int, input().split()))
LR = [tuple(map(int, input().split())) for _ in range(m)]
PQ = [tuple(map(int, input().split())) for _ in range(q)]
MAP = [[0] * (n + 1) for _ in range(n + 1)]
for l, r in LR:
    MAP[l][r] += 1
for i in range(n + 1):
    for j in range(n + 1):
        MAP[i][j] += MAP[i][j - 1]
for i in range(n + 1):
    for j in range(n + 1):
        MAP[i][j] += MAP[i - 1][j]
for p, q in PQ:
    print((MAP[q][q] - (MAP[q][p - 1] + MAP[p - 1][q]) + MAP[p - 1][p - 1]))

-book = [[0] * (n + 1) for _ in range(n + 1)] -for _ in range(m): -    r, l = list(map(int, input().split())) -    book[r][l] += 1 +LR = [tuple(map(int, input().split())) for _ in range(m)] +PQ = [tuple(map(int, input().split())) for _ in range(q)] +MAP = [[0] * (n + 1) for _ in range(n + 1)] +for l, r in LR: +    MAP[l][r] += 1 -        book[i][j] += book[i][j - 1] +        MAP[i][j] += MAP[i][j - 1] -        book[i][j] += book[i - 1][j] -for x, y in [list(map(int, input().split())) for i in range(q)]: -    print((book[y][y] - book[y][x - 1] - book[x - 1][y] + book[x - 1][x - 1])) +        MAP[i][j] += MAP[i - 1][j] +for p, q in PQ: +    print((MAP[q][q] - (MAP[q][p - 1] + MAP[p - 1][q]) + MAP[p - 1][p - 1]))