input = readlines()

n = input.shift.chomp.to_i
v_list = input.shift.chomp.split("\s").map{|x| x.to_i}
c_list = input.shift.chomp.split("\s").map{|x| x.to_i}

r = 0
(1..n).each do |ip|
  i = ip - 1
  diff = v_list[i] - c_list[i]
  r += diff if diff > 0
end

puts r