function main(input){
  
  input = input.split("\n")
  var arr = input[1].split(" ").map(x=>Number(x))
  //drink is 2d array containing (index+1, time)
  var drink = input.slice(3,-1).map(s => s.split(" ").map(x => Number(x)))
  var sum = 0
  for (let i = 0; i<arr.length; i++){
   	sum += arr[i]
  }
  var ans = []
  for (let i = 0; i<Number(input[2]);i++){
    let d = drink[i]
    let r = sum+d[1]-arr[d[0]-1]
    ans.push(r)
   }
   console.log(ans.join("\n"))
}
var input = require("fs").readFileSync(process.argv[2],"utf8")
main(input)