program main
	implicit none
	integer :: N, i, ans
	integer, allocatable :: V(:), C(:)
	read(*, *) N
	allocate(V(1:N), C(1:N))
	read(*, *) V(1:N)
	read(*, *) C(1:N)
	ans = 0
	do i = 1, N
		ans = ans + max(0,V(i)-C(i))
	end do
	write(*, *) ans
end program main