function Main(input) {

  var input = input.split("\n")
  var n = input[0];
  var aryn = input[1].split(" ").map(val => parseInt(val, 10));
  var aryc = input[2].split(" ").map(val => parseInt(val, 10));
  var result = 0;

  for(var i=0;i< n;i++){
    var r = aryn[i] - aryc[i];
    if(r > 0) {
      result = result + r;
    }
  }


  console.log(result);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));