'use strict'

function Main(input) {
    input = input.split("\n")
    const values = input[1].split(' ').map(str => parseInt(str, 10))
    const costs = input[2].split(' ').map(str => parseInt(str, 10))

    const mouke = values.map((v, index) => {
      return v - costs[index]
    }).filter(m => {
      return m > 0
    })

     const result = mouke.reduce((a, b) => {
      return a + b
    }, 0)
    
    console.log(result)
}

Main(require("fs").readFileSync("/dev/stdin", "utf8"))