import Control.Monad
import Data.Array
import Data.Array.ST

main = do
  [n,m,q] <- (map read . words) <$> getLine
  lr0 <- replicateM m (getLine >>= return . map read . words)
  pq0 <- replicateM q (getLine >>= return . map read . words)
  let lrlist = map (\l -> (head l, head $ tail l)) lr0
  let pqlist = map (\l -> (head l, head $ tail l)) pq0
  let train2dimsum = make_2dim_sumlist $ train_number_list_from n lrlist
  sequence_ $ map (query train2dimsum) pqlist

query train2dimsum (p, q) =
  print answer
  where answer =
          train2dimsum!!(q-1)!!(q-1) -
          if p == 1 then
            0
          else
            train2dimsum!!(q-1)!!(p-2) + train2dimsum!!(p-2)!!(q-1) - train2dimsum!!(p-2)!!(p-2)

make_2dim_sumlist l =
  let l2 = map (tail . scanl (+) 0) l in
    tail $ scanl (zipWith (+)) [0, 0 ..] l2

train_number_list_from n lrlist =
  map (\a -> map (\b -> tarray!(a,b)) [1 .. n]) [1 .. n]
  where tarray = runSTArray $
          do
            tstarray <- newArray ((1,1), (n,n)) 0
            sequence_ $ map (update_train_number_array tstarray) lrlist
            return tstarray

update_train_number_array tstarray lr = do
  num <- readArray tstarray lr
  writeArray tstarray lr (num + 1)
