# frozen_string_literal: true

N = gets.to_i
V = gets.split.map(&:to_i)
C = gets.split.map(&:to_i)
D = []
count = 0
N.times do
  D[count] = V[count] - C[count]
  count++
end
ans = 0
count2 = 0
N.times do
    if D[count2] <= 0
        ans += 0
else
    ans += D[count2]
end
p ans
