program main
Implicit None
	integer(8)::n,i,a
	integer(8),allocatable::c(:),v(:)
	
	read*,n
	allocate(c(n),v(n))
	read*,v
	read*,c
	
	a = 0
	do i = 1,n
		if(v(i) > c(i)) a = a+v(I)-c(i)
	enddo
	
	print "(i0)",a
end program main